Leveraging text profiles to select and configure models for use with textual datasets

ABSTRACT

Text profiles can be leveraged to select and configure models according to some examples described herein. In one example, a system can analyze a reference textual dataset and a target textual dataset using text-mining techniques to generate a first text profile and a second text profile, respectively. The first text profile can contain first metrics characterizing the reference textual dataset and the second text profile can contain second metrics characterizing the target textual dataset. The system can determine a similarity value by comparing the first text profile to the second text profile. The system can also receive a user selection of a model that is to be applied to the target textual dataset. The system can then generate an insight relating to an anticipated accuracy of the model on the target textual dataset based on the similarity value. The system can output the insight to the user.

REFERENCE TO RELATED APPLICATIONS

This claims the benefit of priority under 35 U.S.C. § 119(e) to U.S.Provisional Patent Application No. 63/277,764, filed Nov. 10, 2021, andto U.S. Provisional Patent Application No. 63/294,514, filed Dec. 29,2021, the entirety of each of which is hereby incorporated by referenceherein.

TECHNICAL FIELD

The present disclosure relates generally to predicting model performanceon a target textual dataset. More specifically, but not by way oflimitation, this disclosure relates to leveraging text profiles toselect, configure, and test models for use with textual datasets.

BACKGROUND

Textual datasets are commonly analyzed in a variety of industries.Textual datasets may include unstructured text, such as social mediaposts (e.g., tweets), product reviews, service reviews, books, e-mails,word processing documents, etc. Unstructured text refers to naturallanguage text that includes written human language, such as thefree-form text humans type on their keyboards or touch screens.Unstructured text is different from structured data, which is organizedin a pre-defined format from which well-defined semantics can beinferred. Unstructured text is now one of the most common types of datagenerated by humans, and it is growing at an exponential rate.

To derive relevant information from the textual datasets, particularlythose with unstructured text, natural language processing (NLP)techniques can be applied. Some NLP techniques may involve models, suchas rule-driven models, machine-learning models, or hybrids of the two.The machine-learning models may be trained using training data thatcontains annotated (i.e., labeled) textual datasets, such as a labeledcorpus of documents. During training, the machine-learning models learnpatterns found in that training data. As a result, the trained modelsfrequently cannot be reliably or robustly applied to other textualdatasets that have significantly different textual characteristics thanthe training data, such as textual datasets involving different genres,domains, or languages from the ones in the training data. Likewise,rule-driven models are typically configured for use with textualdatasets having certain textual characteristics, such as specificdomains, genres, or languages. As a result, the rule-driven models oftencannot be reliably or robustly applied to textual datasets withsignificantly different characteristics than the ones for which therule-driven models are designed.

SUMMARY

One example of the present disclosure includes a system comprising oneor more processors and one or more memory devices, the one or morememory devices including instructions that are executable by the one ormore processors for causing the one or more processors to: analyze areference textual dataset by applying a plurality of text-miningtechniques to the reference textual dataset to generate a first textprofile containing a first plurality of metrics characterizing thereference textual dataset; analyze a target textual dataset by applyingthe plurality of text-mining techniques to generate a second textprofile containing a second plurality of metrics characterizing thetarget textual dataset; determine a similarity value representing howsimilar the target textual dataset is to the reference textual datasetby comparing the second text profile to the first text profile, whereincomparing the second text profile to the first text profile involvescomparing at least some of the second plurality of metrics to at leastsome of the first plurality of metrics; receive, through a graphicaluser interface and from a user, a selection of a model that is to beapplied to the target textual dataset; in response to receiving theselection, determine characteristics of the model selected by the user,wherein the characteristics include a type and at least one setting ofthe model; generate one or more insights relating to an anticipatedaccuracy of the model on the target textual dataset based on thesimilarity value and the characteristics of the model; and output theone or more insights to the user in the graphical user interface.

Another example of the present disclosure includes a method comprisinganalyzing a reference textual dataset by applying a plurality oftext-mining techniques to the reference textual dataset to generate afirst text profile containing a first plurality of metricscharacterizing the reference textual dataset; analyzing a target textualdataset by applying the plurality of text-mining techniques to generatea second text profile containing a second plurality of metricscharacterizing the target textual dataset; determining a similarityvalue representing how similar the target textual dataset is to thereference textual dataset by comparing the second text profile to thefirst text profile, wherein comparing the second text profile to thefirst text profile involves comparing at least some of the secondplurality of metrics to at least some of the first plurality of metrics;receiving a selection of a model that is to be applied to the targettextual dataset, the selection being received through a graphical userinterface from a user; in response to receiving the selection,determining characteristics of the model selected by the user, whereinthe characteristics include a type and at least one setting of themodel; generating one or more insights relating to an anticipatedaccuracy of the model on the target textual dataset based on thesimilarity value and the characteristics of the model; and outputtingthe one or more insights to the user in the graphical user interface.

Yet another example of the present disclosure includes a non-transitorycomputer-readable medium comprising program code that is executable byone or more processors for causing the one or more processors to:analyze a reference textual dataset by applying a plurality oftext-mining techniques to the reference textual dataset to generate afirst text profile containing a first plurality of metricscharacterizing the reference textual dataset; analyze a target textualdataset by applying the plurality of text-mining techniques to generatea second text profile containing a second plurality of metricscharacterizing the target textual dataset; determine a similarity valuerepresenting how similar the target textual dataset is to the referencetextual dataset by comparing the second text profile to the first textprofile, wherein comparing the second text profile to the first textprofile involves comparing at least some of the second plurality ofmetrics to at least some of the first plurality of metrics; receive,through a graphical user interface and from a user, a selection of amodel that is to be applied to the target textual dataset; in responseto receiving the selection, determine characteristics of the modelselected by the user, wherein the characteristics include a type and atleast one setting of the model; generate one or more insights relatingto an anticipated accuracy of the model on the target textual datasetbased on the similarity value and the characteristics of the model, andoutput the one or more insights to the user in the graphical userinterface.

This summary is not intended to identify key or essential features ofthe claimed subject matter, nor is it intended to be used in isolationto determine the scope of the claimed subject matter. The subject mattershould be understood by reference to appropriate portions of the entirespecification, any or all drawings, and each claim.

The foregoing, together with other features and examples, will becomemore apparent upon referring to the following specification, claims, andaccompanying drawings.

BRIEF DESCRIPTION OF THE DRAWINGS

The present disclosure is described in conjunction with the appendedfigures:

FIG. 1 depicts a block diagram of an example of a computing systemaccording to some aspects.

FIG. 2 depicts an example of devices that can communicate with eachother over an exchange system and via a network according to someaspects.

FIG. 3 depicts a block diagram of a model of an example of acommunications protocol system according to some aspects.

FIG. 4 depicts a hierarchical diagram of an example of a communicationsgrid computing system including a variety of control and worker nodesaccording to some aspects.

FIG. 5 depicts a flow chart of an example of a process for adjusting acommunications grid or a work project in a communications grid after afailure of a node according to some aspects.

FIG. 6 depicts a block diagram of a portion of a communications gridcomputing system including a control node and a worker node according tosome aspects.

FIG. 7 depicts a flow chart of an example of a process for executing adata analysis or processing project according to some aspects.

FIG. 8 depicts a block diagram including components of an Event StreamProcessing Engine (ESPE) according to some aspects.

FIG. 9 depicts a flow chart of an example of a process includingoperations performed by an event stream processing engine according tosome aspects.

FIG. 10 depicts a block diagram of an ESP system interfacing between apublishing device and multiple event subscribing devices according tosome aspects.

FIG. 11 is a flow chart of an example of a process for generating andusing a machine-learning model according to some aspects.

FIG. 12 is a node-link diagram of an example of a neural networkaccording to some aspects.

FIG. 13 is a flow chart of an example of a process executable by aprocessor for generating one or more insights about model behavioraccording to some aspects.

FIG. 14 depicts an example of a bar chart showing anticipated accuracydegradation associated with different types of models according to someaspects.

FIG. 15 depicts an example of categories of metrics according to someaspects.

FIG. 16 is a flow chart of an example of a process for determiningwhether a target textual dataset is relatively homogenous according tosome aspects.

FIG. 17 is a flow chart of an example of a process for determining apredicted level of model degradation based on differences between afirst set of metrics and a second set of metrics according to someaspects.

FIG. 18 is a flow chart of an example of a process for generating adata-preparation recommendation according to some aspects.

FIG. 19 is a flow chart of an example of a process for determining arecommended type of model and a recommended setting value for a modelaccording to some aspects.

FIG. 20 is a chart showing an example of distance values representingthe similarity between pairs of textual datasets according to someaspects.

FIG. 21 is a chart showing an example of normalized Jensen-Shannon (JS)distance values between pairs of textual datasets according to someaspects.

FIG. 22 is a chart showing an example of normalized JS difference scoresrelating to four metrics associated with Casino and Amazon® datasetsaccording to some aspects.

FIG. 23 is a histogram showing an example of raw word-length metrics inrelation to Amazon® and Casino datasets according to some aspects.

FIG. 24 is a histogram showing an example of normalized word-lengthmetrics in relation to Amazon® and Casino datasets according to someaspects.

FIG. 25 is a chart showing an example of normalized JS difference scoresassociated with four metrics relating to sleep abstracts and automotivetechnical notes datasets according to some aspects.

FIG. 26 is a chart showing an example of normalized JS difference scoresassociated with four metrics relating to automotive technical notes andpark datasets according to some aspects.

In the appended figures, similar components or features can have thesame reference label. Further, various components of the same type canbe distinguished by following the reference label with a lowercaseletter that distinguishes among the similar components. If only thefirst reference label is used in the specification, the description isapplicable to any one of the similar components having the same firstreference label irrespective of the lowercase letter.

DETAILED DESCRIPTION

Text data used in Text Analytics and other Natural Language Processing(NLP) modeling is vast and varied. The variation of language can beinfinite and even the variety of information and variance in form thatcan comprise a single sentence is virtually impossible to model in anypractical way. Therefore, any model that “represents” or “understands”human language is representing only the slice of human language that ithas been exposed to or trained on.

Today's NLP models are often built using machine learning or deeplearning techniques, although some use rules or explicit patterns andothers use a combination of these techniques. The secret of all suchmodels is that they all use patterns, and for “learning” models anythingthey have not seen before is a weakness in the model. Applying one modeltrained on a first dataset associated with a first domain on a seconddataset associated with a second domain, where the second domain isdifferent from the first domain, is called “out-of-domain” applicationand usually results in significantly lower accuracy.

These models can be built for a variety of purposes, but some commonexamples of models include document-level sentiment models, feature (ortext-level) sentiment models, document categorization models,information extraction models, part-of-speech tagging models, dependencyparsing models, etc. The text data used with these models can vary fromdomain to domain, and may contain different or similar types ofdocuments. Examples of such documents may include documents produced ina legal action; a set of reviews for a particular product, company, orservice; medical notes for a particular specialty area in a hospital;technical notes from mechanics at an auto dealership; survey resultsfrom open question in a survey on corporate policies; contracts used ina law firm; design documents from an engineering team; news articlesfrom several news websites; tweets related to an event like a protest inLondon; blogs from a particular timeframe; posts from a forum devoted tocar enthusiasts; etc.

These and other issues make it challenging to help an individual thathas a dataset that they wish to process but does not have a modeltrained on that dataset. Perhaps the data has no annotations, so thereis no way to use it as a training set without investing a lot of time ormoney in adding annotations. It would be desirable to help such anindividual understand the following:

-   -   The risk that their model will perform worse on the new,        out-of-domain data;    -   How to mitigate the risk of applying a model to the new data;        and    -   How to select a good model type for the data, if they have a        choice between models.

Until now, there has been no solution offered to these problems. Theexisting research focuses instead on comparing sets of terms, generallyto compare each term and its likelihood to appear in each dataset or itsstrength in representing the topics in a data set. A few researcherscompare datasets to one another, but not for the purposes describedabove. Instead, they focus on research goals such as identifying genericvs. domain-specific data sets, categorizing documents in genres,defining good vs. bad writing at the document level, identifying nativevs. non-native speaker documents, etc. In other words, the focus isusually on the document or words used in the document and not oncomparing datasets to one another to determine the effect on modelingresults.

The current state-of-the-art research that is related to the problem ofapplying models to out-of-domain data focuses on obtaining more and moretraining data (for models that are not supervised) or on “tuning” modelsthat have been trained on a different dataset by optimizing selection ofa sample of data from the new dataset and retraining the model. Thechallenge with the first approach is the language is infinite, and evenif the model is able to be made somewhat robust, the costs are large andthere is always data that is not used in training the model, creatinggaps in the robustness of applying the model to new data. The challengewith the second approach is that the model must be retrained and thatalways changes the model, so the new model's results are not comparablewith older results on previous datasets. Also, the processing requiredto retrain or tune the model may be extensive or expensive depending onthe type of model being used.

As alluded to above, a model's accuracy can vary significantly betweendatasets based on how the model was trained and configured as well asthe characteristics of the datasets to which the model is applied. Forexample, linguistic variation can have a significant impact on how wella model designed for one type of textual dataset performs when appliedto another type of textual dataset. This is due to the fact that mostmodels are built on key words and the order of words in patterns. As aresult, differences in languages and dialects, vocabulary size,vocabulary overlap, grammatical patterns, and other linguisticvariations can result in significant accuracy differences when a modelis applied to textual datasets with different linguisticcharacteristics. This could lead to a situation where the model isrelatively accurate for one dataset but relatively inaccurate foranother. These factors can make it challenging to determine which typeof model or model configuration will work best for a target dataset.Additionally, many users may not be aware of this problem and thus maynot know that the model they are applying to a given textual dataset isexperiencing degraded accuracy due a “mismatch” between the model andthe textual dataset. As a result, users may believe that the model isproducing accurate results when in fact it is not.

Some examples of the present disclosure can overcome one or more of theabove-mentioned problems via a system that can determine how similar areference textual dataset is to a target textual dataset based on thecharacteristics of each dataset. In some examples, the textual datasetsmay include corpora of documents containing unstructured data. Based onthe similarities and differences between the two textual datasets, thesystem can predict whether a model will be suitably accurate whenapplied to the target textual dataset. If the model will not be suitablyaccurate when applied to the target textual dataset, the system candetermine alternative model types or alternative model settings that mayyield more accurate results when applied to the target textual dataset.The system can then output the recommendations to the user in agraphical user interface. This may help the user predict how well theirselected model will perform on the target textual dataset and makeadjustments to improve modeling results.

The solutions offered in the present disclosure are based on the premisethat datasets can be understood by comparing them. If something is knownabout Dataset A, that knowledge may be readily usable if Dataset B issimilar to Dataset A, but may not be readily usable if Dataset B is verydifferent from Dataset A. Some aspects of the present disclosure help toanswer the question of whether Dataset A very similar to or verydifferent from Dataset B. This is not something that has been previouslydone to the same extent (e.g., a detailed and broad comparison oftextual datasets) or to solve the same problem (e.g., providing adviceto maximize use of the data and related models) in previous research orsoftware. While some other work may compute similar metrics andsometimes even compare corpora, the metrics and comparison results arenot then used to generate and provide modeling insights.

The present disclosure can rely on many different aspects of textualdatasets in making these comparisons. Some aspects of textual datasetscan provide a broader view and deeper understanding of the textualdatasets and therefore may create a more complete picture of thedatasets. Examples of such aspects can include the following:

-   -   Vocabulary Diversity: how varied the vocabulary is in the        dataset and how many terms would one need to know to understand        the documents.    -   Information Density: how much information is packed into the        documents and how complex the language/terminology is.    -   Language Formality: how formal the writing style and content is.    -   Information Complexity: how much information is included in each        sentence or clause.    -   Domain Specificity: how domain specific the data set is, and how        specialized or generalized the vocabulary and grammar is.

Some or all of these aspects can be used in the comparative assessmentso as to analyze at textual data from different perspectives and captureinsights that can be useful for different types of models. For example,if the vocabulary of a target data set is very diverse but the model wasbuilt on a less diverse but more domain-specific dataset (source), thenthe overlap in vocabulary may be very small. In other words, the modelsthat rely on vocabulary overlap will perform poorly on the target dataset. While some researchers have looked at multiple datasets from avocabulary perspective, they do not combine that perspective with otherelements to characterize the differences between datasets. In contrast,systems described herein may apply a combination of perspectives andmetrics in a unique way to compare datasets.

One particular example of a system of the present disclosure will now bedescribed for illustrative purpose. In this example, the system cangenerate a graphical user interface through which a user can select atarget textual dataset to be analyzed using a model. After receiving theselection of the target textual dataset, the system can analyze areference textual dataset to determine a first text profile containing afirst set of metrics that characterize the reference textual dataset. Atext profile includes a set of metrics that characterize the textproperties of a textual dataset, where the metrics may be numericalvalues. The text properties may include the lists and characteristics ofwords, the way elements in the text are formed (e.g., tokens, sentences,and documents), patterns of sequences or clusters of elements (e.g.,n-grams, repetition, and duplication), and grammatical structure orcategories (e.g., part-of-speech, syntax, and clause structure). In somecases, the text profile may also include one or more lists of terms(e.g., words or phrases) extracted from the textual dataset, where suchlists of terms are different from the sentences of the textual datasetitself. The system can also analyze the target textual dataset togenerate a second text profile containing a second set of metricscharacterizing the target textual dataset. In some examples, the systemcan generate the first set of metrics and the second set of metricsusing any number and combination of text-mining techniques. Thetext-mining techniques may analyze information complexity, vocabularydiversity, information density, language formality, domain specificity,and other textual characteristics of the corresponding dataset to whichthey are applied. In some examples, the text-mining techniques may usenatural-language processing techniques to derive the metrics. Havingdetermined the first text profile and the second text profile, thesystem can then determine a similarity value representing how similarthe target textual dataset is to the reference textual dataset. This mayinvolve comparing at least some of the metrics in the first set ofmetrics to the corresponding metrics in the second set of metrics. Thesystem may output the first set of metrics, the second set of metrics,the similarity score, or any combination of these in the graphical userinterface.

The user may also be able to select, through the graphical userinterface, a model (e.g., a specific model or a model type) to be usedto analyze the target textual dataset. For example, the user may selecta model from a drop-down menu or list containing a set of candidatemodels for selection. Based on the selection, the system can determinecharacteristics of the selected model. Examples of the characteristicsof the selected model can include a type of the model, a value for asetting of the model, or both. The setting may include a hyperparameter,in some examples. The system can then generate one or more insightsrelating to the anticipated accuracy of the model on the target textualdataset. As used herein, an insight is any useful or potentially usefulinformation about a subject (e.g., topic) of interest that may helpprovide a deeper understanding of the subject. The system can generatethe insights based on the similarity value and the characteristics ofthe model. The system can then output the one or more insights to theuser in the graphical user interface. The insights may allow the user togain a better understanding of how well the model may perform if it isapplied to the target textual dataset. In some examples, the insightsmay include recommendations about how to improve (e.g., optimize)modeling results. The insights may be output as a sentence of wordsgenerated using templates or natural-language generation techniques, sothat the insights are more readily understandable to less-technicalusers that may have less experience or familiarity with modeling.

The reference textual dataset may be used as a baseline of comparison todiscover how the target textual dataset differs from the referencetextual dataset. In some examples, the reference textual dataset may bea general corpus of documents in one or more languages and correspondingto one or more genres or domains for use as a baseline of comparisonwith the target textual dataset. The reference textual dataset may ormay not be in the same domain as the target textual dataset, or have thesame style or level of formality as the target textual dataset, whichmay affect how the model performs on the target textual dataset ascompared to the reference textual dataset.

In other examples, the reference textual dataset may be a corpus ofdocuments with which a specific model was trained. If such a corpus hastextual characteristics that are extremely close to the textualcharacteristics of the target textual dataset to which that model is tobe applied, the model is likely to perform better on the target textualdataset than if the training dataset textual characteristics that arevery different from those of the target textual dataset. This type ofproblem often arises where models are trained in a research environmentand then applied to real-world situations, without re-training orre-tuning efforts that account for these different contexts. As aresult, the models often do not perform as expected in the real-worldsituations. Some examples of the present disclosure can overcome theseproblems by identifying and flagging these types of situations for auser.

For example, the reference textual dataset may be training data that waspreviously used to train the model. The target textual dataset may benew data that was not used to train the model. Based on the similarityscore indicating the similarities and differences between the referencetextual dataset and the target textual dataset, the system can predicthow much accuracy degradation the model will experience if the model isapplied to the target textual dataset. The predicted level of accuracydegradation may be quantified, in some examples, as the estimated amountof loss or the estimated reduction in accuracy that will result if themodel is applied to the target textual dataset as compared to a baselineamount. The baseline amount may be a baseline loss level or a baselineaccuracy level determined using the reference textual dataset. Oncedetermined, the predicted level of accuracy degradation may be output asone of the insights in the graphical user interface.

In some examples, the system can determine a recommended setting valuefor the model (e.g., model type) selected by the user. For example thesystem can apply a set of rules to the second set of metrics todetermine a recommended setting value for the model selected by theuser. The system can then output a recommendation that the user updatethe setting to the recommended value to improve modeling results. Theuser may then update the setting to the recommended value using thegraphical user interface and apply the model with the updated settingvalue to the target textual data.

In some examples, the system can determine a recommended model to applyto the target textual dataset. The recommended model may be a specificmodel or a specific model type, such as a neural network or a regressionmodel. For example the system can apply a set of rules to the second setof metrics to determine a recommended type of model to apply to thetarget textual dataset. If the recommended model is different from themodel selected by the user, the system can output a recommendation thatthe user select the recommended model to improve modeling results. Theuser may then apply the recommended model to the target textual data. Insome examples, the user may be able to interact with the graphical userinterface to select and apply the recommended model.

FIGS. 1-12 depict examples of systems and methods usable for leveragingtext profiles to select and configure models for use with textualdatasets according to some aspects. For example, FIG. 1 is a blockdiagram of an example of the hardware components of a computing systemaccording to some aspects. Data transmission network 100 is aspecialized computer system that may be used for processing largeamounts of data where a large number of computer processing cycles arerequired.

Data transmission network 100 may also include computing environment114. Computing environment 114 may be a specialized computer or othermachine that processes the data received within the data transmissionnetwork 100. The computing environment 114 may include one or more othersystems. For example, computing environment 114 may include a databasesystem 118 or a communications grid 120. The computing environment 114can include one or more processing devices (e.g., distributed over oneor more networks or otherwise in communication with one another) thatmay be collectively be referred to herein as a processor or a processingdevice.

Data transmission network 100 also includes one or more network devices102. Network devices 102 may include client devices that can communicatewith computing environment 114. For example, network devices 102 maysend data to the computing environment 114 to be processed, may sendcommunications to the computing environment 114 to control differentaspects of the computing environment or the data it is processing, amongother reasons. Network devices 102 may interact with the computingenvironment 114 through a number of ways, such as, for example, over oneor more networks 108.

In some examples, network devices 102 may provide a large amount ofdata, either all at once or streaming over a period of time (e.g., usingevent stream processing (ESP)), to the computing environment 114 vianetworks 108. For example, the network devices 102 can transmitelectronic messages for leveraging text profiles to select and configuremodels for use with textual datasets, all at once or streaming over aperiod of time, to the computing environment 114 via networks 108.

The network devices 102 may include network computers, sensors,databases, or other devices that may transmit or otherwise provide datato computing environment 114. For example, network devices 102 mayinclude local area network devices, such as routers, hubs, switches, orother computer networking devices. These devices may provide a varietyof stored or generated data, such as network data or data specific tothe network devices 102 themselves. Network devices 102 may also includesensors that monitor their environment or other devices to collect dataregarding that environment or those devices, and such network devices102 may provide data they collect over time. Network devices 102 mayalso include devices within the internet of things, such as deviceswithin a home automation network. Some of these devices may be referredto as edge devices, and may involve edge-computing circuitry. Data maybe transmitted by network devices 102 directly to computing environment114 or to network-attached data stores, such as network-attached datastores 110 for storage so that the data may be retrieved later by thecomputing environment 114 or other portions of data transmission network100. For example, the network devices 102 can transmit data usable forleveraging text profiles to select and configure models for use withtextual datasets to a network-attached data store 110 for storage. Thecomputing environment 114 may later retrieve the data from thenetwork-attached data store 110 and use the data to lavage text profilesto select and configure models for use with textual datasets.

Network-attached data stores 110 can store data to be processed by thecomputing environment 114 as well as any intermediate or final datagenerated by the computing system in non-volatile memory. But in certainexamples, the configuration of the computing environment 114 allows itsoperations to be performed such that intermediate and final data resultscan be stored solely in volatile memory (e.g., RAM), without arequirement that intermediate or final data results be stored tonon-volatile types of memory (e.g., disk). This can be useful in certainsituations, such as when the computing environment 114 receives ad hocqueries from a user and when responses, which are generated byprocessing large amounts of data, need to be generated dynamically(e.g., on the fly). In this situation, the computing environment 114 maybe configured to retain the processed information within memory so thatresponses can be generated for the user at different levels of detail aswell as allow a user to interactively query against this information.

Network-attached data stores 110 may store a variety of different typesof data organized in a variety of different ways and from a variety ofdifferent sources. For example, network-attached data stores may includestorage other than primary storage located within computing environment114 that is directly accessible by processors located therein.Network-attached data stores may include secondary, tertiary orauxiliary storage, such as large hard drives, servers, virtual memory,among other types. Storage devices may include portable or non-portablestorage devices, optical storage devices, and various other mediumscapable of storing, containing data. A machine-readable storage mediumor computer-readable storage medium may include a non-transitory mediumin which data can be stored and that does not include carrier waves ortransitory electronic communications. Examples of a non-transitorymedium may include, for example, a magnetic disk or tape, opticalstorage media such as compact disk or digital versatile disk, flashmemory, memory or memory devices. A computer-program product may includecode or machine-executable instructions that may represent a procedure,a function, a subprogram, a program, a routine, a subroutine, a module,a software package, a class, or any combination of instructions, datastructures, or program statements. A code segment may be coupled toanother code segment or a hardware circuit by passing or receivinginformation, data, arguments, parameters, or memory contents.Information, arguments, parameters, data, etc. may be passed, forwarded,or transmitted via any suitable means including memory sharing, messagepassing, token passing, network transmission, among others. Furthermore,the data stores may hold a variety of different types of data. Forexample, network-attached data stores 110 may hold unstructured (e.g.,raw) data.

The unstructured data may be presented to the computing environment 114in different forms such as a flat file or a conglomerate of datarecords, and may have data values and accompanying time stamps. Thecomputing environment 114 may be used to analyze the unstructured datain a variety of ways to determine the best way to structure (e.g.,hierarchically) that data, such that the structured data is tailored toa type of further analysis that a user wishes to perform on the data.For example, after being processed, the unstructured time-stamped datamay be aggregated by time (e.g., into daily time period units) togenerate time series data or structured hierarchically according to oneor more dimensions (e.g., parameters, attributes, or variables). Forexample, data may be stored in a hierarchical data structure, such as arelational online analytical processing (ROLAP) or multidimensionalonline analytical processing (MOLAP) database, or may be stored inanother tabular form, such as in a flat-hierarchy form.

Data transmission network 100 may also include one or more server farms106. Computing environment 114 may route select communications or datato the sever farms 106 or one or more servers within the server farms106. Server farms 106 can be configured to provide information in apredetermined manner. For example, server farms 106 may access data totransmit in response to a communication. Server farms 106 may beseparately housed from each other device within data transmissionnetwork 100, such as computing environment 114, or may be part of adevice or system.

Server farms 106 may host a variety of different types of dataprocessing as part of data transmission network 100. Server farms 106may receive a variety of different data from network devices, fromcomputing environment 114, from cloud network 116, or from othersources. The data may have been obtained or collected from one or morewebsites, sensors, as inputs from a control database, or may have beenreceived as inputs from an external system or device. Server farms 106may assist in processing the data by turning raw data into processeddata based on one or more rules implemented by the server farms. Forexample, sensor data may be analyzed to determine changes in anenvironment over time or in real-time.

Data transmission network 100 may also include one or more cloudnetworks 116. Cloud network 116 may include a cloud infrastructuresystem that provides cloud services. In certain examples, servicesprovided by the cloud network 116 may include a host of services thatare made available to users of the cloud infrastructure system ondemand. Cloud network 116 is shown in FIG. 1 as being connected tocomputing environment 114 (and therefore having computing environment114 as its client or user), but cloud network 116 may be connected to orutilized by any of the devices in FIG. 1. Services provided by the cloudnetwork 116 can dynamically scale to meet the needs of its users. Thecloud network 116 may include one or more computers, servers, orsystems. In some examples, the computers, servers, or systems that makeup the cloud network 116 are different from the user's own on-premisescomputers, servers, or systems. For example, the cloud network 116 mayhost an application, and a user may, via a communication network such asthe Internet, order and use the application on demand. In some examples,the cloud network 116 may host an application for leveraging textprofiles to select and configure models for use with textual datasets.

While each device, server, and system in FIG. 1 is shown as a singledevice, multiple devices may instead be used. For example, a set ofnetwork devices can be used to transmit various communications from asingle user, or remote server 140 may include a server stack. As anotherexample, data may be processed as part of computing environment 114.

Each communication within data transmission network 100 (e.g., betweenclient devices, between a device and connection management system 150,between server farms 106 and computing environment 114, or between aserver and a device) may occur over one or more networks 108. Networks108 may include one or more of a variety of different types of networks,including a wireless network, a wired network, or a combination of awired and wireless network. Examples of suitable networks include theInternet, a personal area network, a local area network (LAN), a widearea network (WAN), or a wireless local area network (WLAN). A wirelessnetwork may include a wireless interface or combination of wirelessinterfaces. As an example, a network in the one or more networks 108 mayinclude a short-range communication channel, such as a Bluetooth or aBluetooth Low Energy channel. A wired network may include a wiredinterface. The wired or wireless networks may be implemented usingrouters, access points, bridges, gateways, or the like, to connectdevices in the network 108. The networks 108 can be incorporatedentirely within or can include an intranet, an extranet, or acombination thereof. In one example, communications between two or moresystems or devices can be achieved by a secure communications protocol,such as secure sockets layer (SSL) or transport layer security (TLS). Inaddition, data or transactional details may be encrypted.

Some aspects may utilize the Internet of Things (IoT), where things(e.g., machines, devices, phones, sensors) can be connected to networksand the data from these things can be collected and processed within thethings or external to the things. For example, the IoT can includesensors in many different devices, and high value analytics can beapplied to identify hidden relationships and drive increasedefficiencies. This can apply to both big data analytics and real-time(e.g., ESP) analytics.

As noted, computing environment 114 may include a communications grid120 and a transmission network database system 118. Communications grid120 may be a grid-based computing system for processing large amounts ofdata. The transmission network database system 118 may be for managing,storing, and retrieving large amounts of data that are distributed toand stored in the one or more network-attached data stores 110 or otherdata stores that reside at different locations within the transmissionnetwork database system 118. The computing nodes in the communicationsgrid 120 and the transmission network database system 118 may share thesame processor hardware, such as processors that are located withincomputing environment 114.

In some examples, the computing environment 114, a network device 102,or both can implement one or more processes for leveraging text profilesto select and configure models for use with textual datasets. Forexample, the computing environment 114, a network device 102, or bothcan implement one or more versions of the processes discussed withrespect to any of the figures.

FIG. 2 is an example of devices that can communicate with each otherover an exchange system and via a network according to some aspects. Asnoted, each communication within data transmission network 100 may occurover one or more networks. System 200 includes a network device 204configured to communicate with a variety of types of client devices, forexample client devices 230, over a variety of types of communicationchannels.

As shown in FIG. 2, network device 204 can transmit a communication overa network (e.g., a cellular network via a base station 210). In someexamples, the communication can include times series data. Thecommunication can be routed to another network device, such as networkdevices 205-209, via base station 210. The communication can also berouted to computing environment 214 via base station 210. In someexamples, the network device 204 may collect data either from itssurrounding environment or from other network devices (such as networkdevices 205-209) and transmit that data to computing environment 214.

Although network devices 204-209 are shown in FIG. 2 as a mobile phone,laptop computer, tablet computer, temperature sensor, motion sensor, andaudio sensor respectively, the network devices may be or include sensorsthat are sensitive to detecting aspects of their environment. Forexample, the network devices may include sensors such as water sensors,power sensors, electrical current sensors, chemical sensors, opticalsensors, pressure sensors, geographic or position sensors (e.g., GPS),velocity sensors, acceleration sensors, flow rate sensors, among others.Examples of characteristics that may be sensed include force, torque,load, strain, position, temperature, air pressure, fluid flow, chemicalproperties, resistance, electromagnetic fields, radiation, irradiance,proximity, acoustics, moisture, distance, speed, vibrations,acceleration, electrical potential, and electrical current, amongothers. The sensors may be mounted to various components used as part ofa variety of different types of systems. The network devices may detectand record data related to the environment that it monitors, andtransmit that data to computing environment 214.

The network devices 204-209 may also perform processing on data itcollects before transmitting the data to the computing environment 214,or before deciding whether to transmit data to the computing environment214. For example, network devices 204-209 may determine whether datacollected meets certain rules, for example by comparing data or valuescalculated from the data and comparing that data to one or morethresholds. The network devices 204-209 may use this data or comparisonsto determine if the data is to be transmitted to the computingenvironment 214 for further use or processing. In some examples, thenetwork devices 204-209 can pre-process the data prior to transmittingthe data to the computing environment 214. For example, the networkdevices 204-209 can reformat the data before transmitting the data tothe computing environment 214 for further processing.

Computing environment 214 may include machines 220, 240. Althoughcomputing environment 214 is shown in FIG. 2 as having two machines 220,240, computing environment 214 may have only one machine or may havemore than two machines. The machines 220, 240 that make up computingenvironment 214 may include specialized computers, servers, or othermachines that are configured to individually or collectively processlarge amounts of data. The computing environment 214 may also includestorage devices that include one or more databases of structured data,such as data organized in one or more hierarchies, or unstructured data.The databases may communicate with the processing devices withincomputing environment 214 to distribute data to them. Since networkdevices may transmit data to computing environment 214, that data may bereceived by the computing environment 214 and subsequently stored withinthose storage devices. Data used by computing environment 214 may alsobe stored in data stores 235, which may also be a part of or connectedto computing environment 214.

Computing environment 214 can communicate with various devices via oneor more routers 225 or other inter-network or intra-network connectioncomponents. For example, computing environment 214 may communicate withclient devices 230 via one or more routers 225. Computing environment214 may collect, analyze or store data from or pertaining tocommunications, client device operations, client rules, oruser-associated actions stored at one or more data stores 235. Such datamay influence communication routing to the devices within computingenvironment 214, how data is stored or processed within computingenvironment 214, among other actions.

Notably, various other devices can further be used to influencecommunication routing or processing between devices within computingenvironment 214 and with devices outside of computing environment 214.For example, as shown in FIG. 2, computing environment 214 may include amachine 240 that is a web server. Computing environment 214 can retrievedata of interest, such as client information (e.g., product information,client rules, etc.), technical product details, news, blog posts,e-mails, forum posts, electronic documents, social media posts (e.g.,Twitter™ posts or Facebook™ posts), time series data, and so on.

In addition to computing environment 214 collecting data (e.g., asreceived from network devices, such as sensors, and client devices orother sources) to be processed as part of a big data analytics project,it may also receive data in real time as part of a streaming analyticsenvironment. As noted, data may be collected using a variety of sourcesas communicated via different kinds of networks or locally. Such datamay be received on a real-time streaming basis. For example, networkdevices 204-209 may receive data periodically and in real time from aweb server or other source. Devices within computing environment 214 mayalso perform pre-analysis on data it receives to determine if the datareceived should be processed as part of an ongoing project. For example,as part of a project for leveraging text profiles to select andconfigure models, the computing environment 214 can perform apre-analysis of the data. The pre-analysis can include determiningwhether the data is in a correct format for leveraging text profiles toselect and configure models for use with textual datasets and, if not,reformatting the data into the correct format.

FIG. 3 is a block diagram of a model of an example of a communicationsprotocol system according to some aspects. More specifically, FIG. 3identifies operation of a computing environment in an Open SystemsInteraction model that corresponds to various connection components. Themodel 300 shows, for example, how a computing environment, such ascomputing environment (or computing environment 214 in FIG. 2) maycommunicate with other devices in its network, and control howcommunications between the computing environment and other devices areexecuted and under what conditions.

The model 300 can include layers 302-314. The layers 302-314 arearranged in a stack. Each layer in the stack serves the layer one levelhigher than it (except for the application layer, which is the highestlayer), and is served by the layer one level below it (except for thephysical layer 302, which is the lowest layer). The physical layer 302is the lowest layer because it receives and transmits raw bites of data,and is the farthest layer from the user in a communications system. Onthe other hand, the application layer is the highest layer because itinteracts directly with a software application.

As noted, the model 300 includes a physical layer 302. Physical layer302 represents physical communication, and can define parameters of thatphysical communication. For example, such physical communication maycome in the form of electrical, optical, or electromagneticcommunications. Physical layer 302 also defines protocols that maycontrol communications within a data transmission network.

Link layer 304 defines links and mechanisms used to transmit (e.g.,move) data across a network. The link layer manages node-to-nodecommunications, such as within a grid-computing environment. Link layer304 can detect and correct errors (e.g., transmission errors in thephysical layer 302). Link layer 304 can also include a media accesscontrol (MAC) layer and logical link control (LLC) layer.

Network layer 306 can define the protocol for routing within a network.In other words, the network layer coordinates transferring data acrossnodes in a same network (e.g., such as a grid-computing environment).Network layer 306 can also define the processes used to structure localaddressing within the network.

Transport layer 308 can manage the transmission of data and the qualityof the transmission or receipt of that data. Transport layer 308 canprovide a protocol for transferring data, such as, for example, aTransmission Control Protocol (TCP). Transport layer 308 can assembleand disassemble data frames for transmission. The transport layer canalso detect transmission errors occurring in the layers below it.

Session layer 310 can establish, maintain, and manage communicationconnections between devices on a network. In other words, the sessionlayer controls the dialogues or nature of communications between networkdevices on the network. The session layer may also establishcheckpointing, adjournment, termination, and restart procedures.

Presentation layer 312 can provide translation for communicationsbetween the application and network layers. In other words, this layermay encrypt, decrypt or format data based on data types known to beaccepted by an application or network layer.

Application layer 314 interacts directly with software applications andend users, and manages communications between them. Application layer314 can identify destinations, local resource states or availability orcommunication content or formatting using the applications.

For example, a communication link can be established between two deviceson a network. One device can transmit an analog or digitalrepresentation of an electronic message that includes a dataset to theother device. The other device can receive the analog or digitalrepresentation at the physical layer 302. The other device can transmitthe data associated with the electronic message through the remaininglayers 304-314. The application layer 314 can receive data associatedwith the electronic message. The application layer 314 can identify oneor more applications, such as an application for leveraging textprofiles to select and configure models for use with textual datasets,to which to transmit data associated with the electronic message. Theapplication layer 314 can transmit the data to the identifiedapplication.

Intra-network connection components 322, 324 can operate in lowerlevels, such as physical layer 302 and link layer 304, respectively. Forexample, a hub can operate in the physical layer, a switch can operatein the physical layer, and a router can operate in the network layer.Inter-network connection components 326, 328 are shown to operate onhigher levels, such as layers 306-314. For example, routers can operatein the network layer and network devices can operate in the transport,session, presentation, and application layers.

A computing environment 330 can interact with or operate on, in variousexamples, one, more, all or any of the various layers. For example,computing environment 330 can interact with a hub (e.g., via the linklayer) to adjust which devices the hub communicates with. The physicallayer 302 may be served by the link layer 304, so it may implement suchdata from the link layer 304. For example, the computing environment 330may control which devices from which it can receive data. For example,if the computing environment 330 knows that a certain network device hasturned off, broken, or otherwise become unavailable or unreliable, thecomputing environment 330 may instruct the hub to prevent any data frombeing transmitted to the computing environment 330 from that networkdevice. Such a process may be beneficial to avoid receiving data that isinaccurate or that has been influenced by an uncontrolled environment.As another example, computing environment 330 can communicate with abridge, switch, router or gateway and influence which device within thesystem (e.g., system 200) the component selects as a destination. Insome examples, computing environment 330 can interact with variouslayers by exchanging communications with equipment operating on aparticular layer by routing or modifying existing communications. Inanother example, such as in a grid-computing environment, a node maydetermine how data within the environment should be routed (e.g., whichnode should receive certain data) based on certain parameters orinformation provided by other layers within the model.

The computing environment 330 may be a part of a communications gridenvironment, the communications of which may be implemented as shown inthe protocol of FIG. 3. For example, referring back to FIG. 2, one ormore of machines 220 and 240 may be part of a communicationsgrid-computing environment. A gridded computing environment may beemployed in a distributed system with non-interactive workloads wheredata resides in memory on the machines, or compute nodes. In such anenvironment, analytic code, instead of a database management system, cancontrol the processing performed by the nodes. Data is co-located bypre-distributing it to the grid nodes, and the analytic code on eachnode loads the local data into memory. Each node may be assigned aparticular task, such as a portion of a processing project, or toorganize or control other nodes within the grid. For example, each nodemay be assigned a portion of a processing task for testing a softwareapplication.

FIG. 4 is a hierarchical diagram of an example of a communications gridcomputing system 400 including a variety of control and worker nodesaccording to some aspects. Communications grid computing system 400includes three control nodes and one or more worker nodes.Communications grid computing system 400 includes control nodes 402,404, and 406. The control nodes are communicatively connected viacommunication paths 451, 453, and 455. The control nodes 402-406 maytransmit information (e.g., related to the communications grid ornotifications) to and receive information from each other. Althoughcommunications grid computing system 400 is shown in FIG. 4 as includingthree control nodes, the communications grid may include more or lessthan three control nodes.

Communications grid computing system 400 (which can be referred to as a“communications grid”) also includes one or more worker nodes. Shown inFIG. 4 are six worker nodes 410-420. Although FIG. 4 shows six workernodes, a communications grid can include more or less than six workernodes. The number of worker nodes included in a communications grid maybe dependent upon how large the project or dataset is being processed bythe communications grid, the capacity of each worker node, the timedesignated for the communications grid to complete the project, amongothers. Each worker node within the communications grid computing system400 may be connected (wired or wirelessly, and directly or indirectly)to control nodes 402-406. Each worker node may receive information fromthe control nodes (e.g., an instruction to perform work on a project)and may transmit information to the control nodes (e.g., a result fromwork performed on a project). Furthermore, worker nodes may communicatewith each other directly or indirectly. For example, worker nodes maytransmit data between each other related to a job being performed or anindividual task within a job being performed by that worker node. Insome examples, worker nodes may not be connected (communicatively orotherwise) to certain other worker nodes. For example, a worker node 410may only be able to communicate with a particular control node 402. Theworker node 410 may be unable to communicate with other worker nodes412-420 in the communications grid, even if the other worker nodes412-420 are controlled by the same control node 402.

A control node 402-406 may connect with an external device with whichthe control node 402-406 may communicate (e.g., a communications griduser, such as a server or computer, may connect to a controller of thegrid). For example, a server or computer may connect to control nodes402-406 and may transmit a project or job to the node, such as a projector job related to testing a software application. The project mayinclude a dataset. The dataset may be of any size and can includeoverride data or debugging data. Once the control node 402-406 receivessuch a project, the control node may distribute the dataset or projectsrelated to the dataset to be performed by worker nodes. Alternatively,the dataset may be receive or stored by a machine other than a controlnode 402-406 (e.g., a Hadoop data node).

Control nodes 402-406 can maintain knowledge of the status of the nodesin the grid (e.g., grid status information), accept work requests fromclients, subdivide the work across worker nodes, and coordinate theworker nodes, among other responsibilities. Worker nodes 412-420 mayaccept work requests from a control node 402-406 and provide the controlnode with results of the work performed by the worker node. A grid maybe started from a single node (e.g., a machine, computer, server, etc.).This first node may be assigned or may start as the primary control node402 that will control any additional nodes that enter the grid.

When a project is submitted for execution (e.g., by a client or acontroller of the grid) it may be assigned to a set of nodes. After thenodes are assigned to a project, a data structure (e.g., a communicator)may be created. The communicator may be used by the project forinformation to be shared between the project code running on each node.A communication handle may be created on each node. A handle, forexample, is a reference to the communicator that is valid within asingle process on a single node, and the handle may be used whenrequesting communications between nodes.

A control node, such as control node 402, may be designated as theprimary control node. A server, computer or other external device mayconnect to the primary control node. Once the control node 402 receivesa project, the primary control node may distribute portions of theproject to its worker nodes for execution. For example, a project fortesting a software application can be initiated on communications gridcomputing system 400. A primary control node can control the work to beperformed for the project in order to complete the project as requestedor instructed. The primary control node may distribute work to theworker nodes 412-420 based on various factors, such as which subsets orportions of projects may be completed most efficiently and in thecorrect amount of time. For example, a worker node 412 may test asoftware application using at least a portion of data that is alreadylocal (e.g., stored on) the worker node. The primary control node alsocoordinates and processes the results of the work performed by eachworker node 412-420 after each worker node 412-420 executes andcompletes its job. For example, the primary control node may receive aresult from one or more worker nodes 412-420, and the primary controlnode may organize (e.g., collect and assemble) the results received andcompile them to produce a complete result for the project received fromthe end user.

Any remaining control nodes, such as control nodes 404, 406, may beassigned as backup control nodes for the project. In an example, backupcontrol nodes may not control any portion of the project. Instead,backup control nodes may serve as a backup for the primary control nodeand take over as primary control node if the primary control node wereto fail. If a communications grid were to include only a single controlnode 402, and the control node 402 were to fail (e.g., the control nodeis shut off or breaks) then the communications grid as a whole may failand any project or job being run on the communications grid may fail andmay not complete. While the project may be run again, such a failure maycause a delay (severe delay in some cases, such as overnight delay) incompletion of the project. Therefore, a grid with multiple control nodes402-406, including a backup control node, may be beneficial.

In some examples, the primary control node may open a pair of listeningsockets to add another node or machine to the grid. A socket may be usedto accept work requests from clients, and the second socket may be usedto accept connections from other grid nodes. The primary control nodemay be provided with a list of other nodes (e.g., other machines,computers, servers, etc.) that can participate in the grid, and the rolethat each node can fill in the grid. Upon startup of the primary controlnode (e.g., the first node on the grid), the primary control node mayuse a network protocol to start the server process on every other nodein the grid. Command line parameters, for example, may inform each nodeof one or more pieces of information, such as: the role that the nodewill have in the grid, the host name of the primary control node, theport number on which the primary control node is accepting connectionsfrom peer nodes, among others. The information may also be provided in aconfiguration file, transmitted over a secure shell tunnel, recoveredfrom a configuration server, among others. While the other machines inthe grid may not initially know about the configuration of the grid,that information may also be sent to each other node by the primarycontrol node. Updates of the grid information may also be subsequentlysent to those nodes.

For any control node other than the primary control node added to thegrid, the control node may open three sockets. The first socket mayaccept work requests from clients, the second socket may acceptconnections from other grid members, and the third socket may connect(e.g., permanently) to the primary control node. When a control node(e.g., primary control node) receives a connection from another controlnode, it first checks to see if the peer node is in the list ofconfigured nodes in the grid. If it is not on the list, the control nodemay clear the connection. If it is on the list, it may then attempt toauthenticate the connection. If authentication is successful, theauthenticating node may transmit information to its peer, such as theport number on which a node is listening for connections, the host nameof the node, information about how to authenticate the node, among otherinformation. When a node, such as the new control node, receivesinformation about another active node, it can check to see if it alreadyhas a connection to that other node. If it does not have a connection tothat node, it may then establish a connection to that control node.

Any worker node added to the grid may establish a connection to theprimary control node and any other control nodes on the grid. Afterestablishing the connection, it may authenticate itself to the grid(e.g., any control nodes, including both primary and backup, or a serveror user controlling the grid). After successful authentication, theworker node may accept configuration information from the control node.

When a node joins a communications grid (e.g., when the node is poweredon or connected to an existing node on the grid or both), the node isassigned (e.g., by an operating system of the grid) a universally uniqueidentifier (UUID). This unique identifier may help other nodes andexternal entities (devices, users, etc.) to identify the node anddistinguish it from other nodes. When a node is connected to the grid,the node may share its unique identifier with the other nodes in thegrid. Since each node may share its unique identifier, each node mayknow the unique identifier of every other node on the grid. Uniqueidentifiers may also designate a hierarchy of each of the nodes (e.g.,backup control nodes) within the grid. For example, the uniqueidentifiers of each of the backup control nodes may be stored in a listof backup control nodes to indicate an order in which the backup controlnodes will take over for a failed primary control node to become a newprimary control node. But, a hierarchy of nodes may also be determinedusing methods other than using the unique identifiers of the nodes. Forexample, the hierarchy may be predetermined, or may be assigned based onother predetermined factors.

The grid may add new machines at any time (e.g., initiated from anycontrol node). Upon adding a new node to the grid, the control node mayfirst add the new node to its table of grid nodes. The control node mayalso then notify every other control node about the new node. The nodesreceiving the notification may acknowledge that they have updated theirconfiguration information.

Primary control node 402 may, for example, transmit one or morecommunications to backup control nodes 404, 406 (and, for example, toother control or worker nodes 412-420 within the communications grid).Such communications may be sent periodically, at fixed time intervals,between known fixed stages of the project's execution, among otherprotocols. The communications transmitted by primary control node 402may be of varied types and may include a variety of types ofinformation. For example, primary control node 402 may transmitsnapshots (e.g., status information) of the communications grid so thatbackup control node 404 always has a recent snapshot of thecommunications grid. The snapshot or grid status may include, forexample, the structure of the grid (including, for example, the workernodes 410-420 in the communications grid, unique identifiers of theworker nodes 410-420, or their relationships with the primary controlnode 402) and the status of a project (including, for example, thestatus of each worker node's portion of the project). The snapshot mayalso include analysis or results received from worker nodes 410-420 inthe communications grid. The backup control nodes 404, 406 may receiveand store the backup data received from the primary control node 402.The backup control nodes 404, 406 may transmit a request for such asnapshot (or other information) from the primary control node 402, orthe primary control node 402 may send such information periodically tothe backup control nodes 404, 406.

As noted, the backup data may allow a backup control node 404, 406 totake over as primary control node if the primary control node 402 failswithout requiring the communications grid to start the project over fromscratch. If the primary control node 402 fails, the backup control node404, 406 that will take over as primary control node may retrieve themost recent version of the snapshot received from the primary controlnode 402 and use the snapshot to continue the project from the stage ofthe project indicated by the backup data. This may prevent failure ofthe project as a whole.

A backup control node 404, 406 may use various methods to determine thatthe primary control node 402 has failed. In one example of such amethod, the primary control node 402 may transmit (e.g., periodically) acommunication to the backup control node 404, 406 that indicates thatthe primary control node 402 is working and has not failed, such as aheartbeat communication. The backup control node 404, 406 may determinethat the primary control node 402 has failed if the backup control nodehas not received a heartbeat communication for a certain predeterminedperiod of time. Alternatively, a backup control node 404, 406 may alsoreceive a communication from the primary control node 402 itself (beforeit failed) or from a worker node 410-420 that the primary control node402 has failed, for example because the primary control node 402 hasfailed to communicate with the worker node 410-420.

Different methods may be performed to determine which backup controlnode of a set of backup control nodes (e.g., backup control nodes 404,406) can take over for failed primary control node 402 and become thenew primary control node. For example, the new primary control node maybe chosen based on a ranking or “hierarchy” of backup control nodesbased on their unique identifiers. In an alternative example, a backupcontrol node may be assigned to be the new primary control node byanother device in the communications grid or from an external device(e.g., a system infrastructure or an end user, such as a server orcomputer, controlling the communications grid). In another alternativeexample, the backup control node that takes over as the new primarycontrol node may be designated based on bandwidth or other statisticsabout the communications grid.

A worker node within the communications grid may also fail. If a workernode fails, work being performed by the failed worker node may beredistributed amongst the operational worker nodes. In an alternativeexample, the primary control node may transmit a communication to eachof the operable worker nodes still on the communications grid that eachof the worker nodes should purposefully fail also. After each of theworker nodes fail, they may each retrieve their most recent savedcheckpoint of their status and re-start the project from that checkpointto minimize lost progress on the project being executed. In someexamples, a communications grid computing system 400 can be used toimplement one or more features described herein, for example to test asoftware application.

FIG. 5 is a flow chart of an example of a process for adjusting acommunications grid or a work project in a communications grid after afailure of a node according to some aspects. The process may include,for example, receiving grid status information including a projectstatus of a portion of a project being executed by a node in thecommunications grid, as described in operation 502. For example, acontrol node (e.g., a backup control node connected to a primary controlnode and a worker node on a communications grid) may receive grid statusinformation, where the grid status information includes a project statusof the primary control node or a project status of the worker node. Theproject status of the primary control node and the project status of theworker node may include a status of one or more portions of a projectbeing executed by the primary and worker nodes in the communicationsgrid. The process may also include storing the grid status information,as described in operation 504. For example, a control node (e.g., abackup control node) may store the received grid status informationlocally within the control node. Alternatively, the grid statusinformation may be sent to another device for storage where the controlnode may have access to the information.

The process may also include receiving a failure communicationcorresponding to a node in the communications grid in operation 506. Forexample, a node may receive a failure communication including anindication that the primary control node has failed, prompting a backupcontrol node to take over for the primary control node. In analternative embodiment, a node may receive a failure that a worker nodehas failed, prompting a control node to reassign the work beingperformed by the worker node. The process may also include reassigning anode or a portion of the project being executed by the failed node, asdescribed in operation 508. For example, a control node may designatethe backup control node as a new primary control node based on thefailure communication upon receiving the failure communication. If thefailed node is a worker node, a control node may identify a projectstatus of the failed worker node using the snapshot of thecommunications grid, where the project status of the failed worker nodeincludes a status of a portion of the project being executed by thefailed worker node at the failure time.

The process may also include receiving updated grid status informationbased on the reassignment, as described in operation 510, andtransmitting a set of instructions based on the updated grid statusinformation to one or more nodes in the communications grid, asdescribed in operation 512. The updated grid status information mayinclude an updated project status of the primary control node or anupdated project status of the worker node. The updated information maybe transmitted to the other nodes in the grid to update their stalestored information.

FIG. 6 is a block diagram of a portion of a communications gridcomputing system 600 including a control node and a worker nodeaccording to some aspects. Communications grid 600 computing systemincludes one control node (control node 602) and one worker node (workernode 610) for purposes of illustration, but may include more workerand/or control nodes. The control node 602 is communicatively connectedto worker node 610 via communication path 650. Therefore, control node602 may transmit information (e.g., related to the communications gridor notifications), to and receive information from worker node 610 viacommunication path 650.

Similar to in FIG. 4, communications grid computing system (or just“communications grid”) 600 includes data processing nodes (control node602 and worker node 610). Nodes 602 and 610 comprise multi-core dataprocessors. Each node 602 and 610 includes a grid-enabled softwarecomponent (GESC) 620 that executes on the data processor associated withthat node and interfaces with buffer memory 622 also associated withthat node. Each node 602 and 610 includes database management software(DBMS) 628 that executes on a database server (not shown) at controlnode 602 and on a database server (not shown) at worker node 610.

Each node also includes a data store 624. Data stores 624, similar tonetwork-attached data stores 110 in FIG. 1 and data stores 235 in FIG.2, are used to store data to be processed by the nodes in the computingenvironment. Data stores 624 may also store any intermediate or finaldata generated by the computing system after being processed, forexample in non-volatile memory. However in certain examples, theconfiguration of the grid computing environment allows its operations tobe performed such that intermediate and final data results can be storedsolely in volatile memory (e.g., RAM), without a requirement thatintermediate or final data results be stored to non-volatile types ofmemory. Storing such data in volatile memory may be useful in certainsituations, such as when the grid receives queries (e.g., ad hoc) from aclient and when responses, which are generated by processing largeamounts of data, need to be generated quickly or on-the-fly. In such asituation, the grid may be configured to retain the data within memoryso that responses can be generated at different levels of detail and sothat a client may interactively query against this information.

Each node also includes a user-defined function (UDF) 626. The UDFprovides a mechanism for the DMBS 628 to transfer data to or receivedata from the database stored in the data stores 624 that are managed bythe DBMS. For example, UDF 626 can be invoked by the DBMS to providedata to the GESC for processing. The UDF 626 may establish a socketconnection (not shown) with the GESC to transfer the data.Alternatively, the UDF 626 can transfer data to the GESC by writing datato shared memory accessible by both the UDF and the GESC.

The GESC 620 at the nodes 602 and 610 may be connected via a network,such as network 108 shown in FIG. 1. Therefore, nodes 602 and 610 cancommunicate with each other via the network using a predeterminedcommunication protocol such as, for example, the Message PassingInterface (MPI). Each GESC 620 can engage in point-to-pointcommunication with the GESC at another node or in collectivecommunication with multiple GESCs via the network. The GESC 620 at eachnode may contain identical (or nearly identical) software instructions.Each node may be capable of operating as either a control node or aworker node. The GESC at the control node 602 can communicate, over acommunication path 652, with a client device 630. More specifically,control node 602 may communicate with client application 632 hosted bythe client device 630 to receive queries and to respond to those queriesafter processing large amounts of data.

DMBS 628 may control the creation, maintenance, and use of database ordata structure (not shown) within nodes 602 or 610. The database mayorganize data stored in data stores 624. The DMBS 628 at control node602 may accept requests for data and transfer the appropriate data forthe request. With such a process, collections of data may be distributedacross multiple physical locations. In this example, each node 602 and610 stores a portion of the total data managed by the management systemin its associated data store 624.

Furthermore, the DBMS may be responsible for protecting against dataloss using replication techniques. Replication includes providing abackup copy of data stored on one node on one or more other nodes.Therefore, if one node fails, the data from the failed node can berecovered from a replicated copy residing at another node. However, asdescribed herein with respect to FIG. 4, data or status information foreach node in the communications grid may also be shared with each nodeon the grid.

FIG. 7 is a flow chart of an example of a process for executing a dataanalysis or a processing project according to some aspects. As describedwith respect to FIG. 6, the GESC at the control node may transmit datawith a client device (e.g., client device 630) to receive queries forexecuting a project and to respond to those queries after large amountsof data have been processed. The query may be transmitted to the controlnode, where the query may include a request for executing a project, asdescribed in operation 702. The query can contain instructions on thetype of data analysis to be performed in the project and whether theproject should be executed using the grid-based computing environment,as shown in operation 704.

To initiate the project, the control node may determine if the queryrequests use of the grid-based computing environment to execute theproject. If the determination is no, then the control node initiatesexecution of the project in a solo environment (e.g., at the controlnode), as described in operation 710. If the determination is yes, thecontrol node may initiate execution of the project in the grid-basedcomputing environment, as described in operation 706. In such asituation, the request may include a requested configuration of thegrid. For example, the request may include a number of control nodes anda number of worker nodes to be used in the grid when executing theproject. After the project has been completed, the control node maytransmit results of the analysis yielded by the grid, as described inoperation 708. Whether the project is executed in a solo or grid-basedenvironment, the control node provides the results of the project.

As noted with respect to FIG. 2, the computing environments describedherein may collect data (e.g., as received from network devices, such assensors, such as network devices 204-209 in FIG. 2, and client devicesor other sources) to be processed as part of a data analytics project,and data may be received in real time as part of a streaming analyticsenvironment (e.g., ESP). Data may be collected using a variety ofsources as communicated via different kinds of networks or locally, suchas on a real-time streaming basis. For example, network devices mayreceive data periodically from network device sensors as the sensorscontinuously sense, monitor and track changes in their environments.More specifically, an increasing number of distributed applicationsdevelop or produce continuously flowing data from distributed sources byapplying queries to the data before distributing the data togeographically distributed recipients. An event stream processing engine(ESPE) may continuously apply the queries to the data as it is receivedand determines which entities should receive the data. Client or otherdevices may also subscribe to the ESPE or other devices processing ESPdata so that they can receive data after processing, based on forexample the entities determined by the processing engine. For example,client devices 230 in FIG. 2 may subscribe to the ESPE in computingenvironment 214. In another example, event subscription devices 1024a-c, described further with respect to FIG. 10, may also subscribe tothe ESPE. The ESPE may determine or define how input data or eventstreams from network devices or other publishers (e.g., network devices204-209 in FIG. 2) are transformed into meaningful output data to beconsumed by subscribers, such as for example client devices 230 in FIG.2.

FIG. 8 is a block diagram including components of an Event StreamProcessing Engine (ESPE) according to some aspects. ESPE 800 may includeone or more projects 802. A project may be described as a second-levelcontainer in an engine model managed by ESPE 800 where a thread poolsize for the project may be defined by a user. Each project of the oneor more projects 802 may include one or more continuous queries 804 thatcontain data flows, which are data transformations of incoming eventstreams. The one or more continuous queries 804 may include one or moresource windows 806 and one or more derived windows 808.

The ESPE may receive streaming data over a period of time related tocertain events, such as events or other data sensed by one or morenetwork devices. The ESPE may perform operations associated withprocessing data created by the one or more devices. For example, theESPE may receive data from the one or more network devices 204-209 shownin FIG. 2. As noted, the network devices may include sensors that sensedifferent aspects of their environments, and may collect data over timebased on those sensed observations. For example, the ESPE may beimplemented within one or more of machines 220 and 240 shown in FIG. 2.The ESPE may be implemented within such a machine by an ESP application.An ESP application may embed an ESPE with its own dedicated thread poolor pools into its application space where the main application threadcan do application-specific work and the ESPE processes event streams atleast by creating an instance of a model into processing objects.

The engine container is the top-level container in a model that managesthe resources of the one or more projects 802. In an illustrativeexample, there may be only one ESPE 800 for each instance of the ESPapplication, and ESPE 800 may have a unique engine name. Additionally,the one or more projects 802 may each have unique project names, andeach query may have a unique continuous query name and begin with auniquely named source window of the one or more source windows 806. ESPE800 may or may not be persistent.

Continuous query modeling involves defining directed graphs of windowsfor event stream manipulation and transformation. A window in thecontext of event stream manipulation and transformation is a processingnode in an event stream processing model. A window in a continuous querycan perform aggregations, computations, pattern-matching, and otheroperations on data flowing through the window. A continuous query may bedescribed as a directed graph of source, relational, pattern matching,and procedural windows. The one or more source windows 806 and the oneor more derived windows 808 represent continuously executing queriesthat generate updates to a query result set as new event blocks streamthrough ESPE 800. A directed graph, for example, is a set of nodesconnected by edges, where the edges have a direction associated withthem.

An event object may be described as a packet of data accessible as acollection of fields, with at least one of the fields defined as a keyor unique identifier (ID). The event object may be created using avariety of formats including binary, alphanumeric, XML, etc. Each eventobject may include one or more fields designated as a primary identifier(ID) for the event so ESPE 800 can support operation codes (opcodes) forevents including insert, update, upsert, and delete. Upsert opcodesupdate the event if the key field already exists; otherwise, the eventis inserted. For illustration, an event object may be a packed binaryrepresentation of a set of field values and include both metadata andfield data associated with an event. The metadata may include an opcodeindicating if the event represents an insert, update, delete, or upsert,a set of flags indicating if the event is a normal, partial-update, or aretention generated event from retention policy management, and a set ofmicrosecond timestamps that can be used for latency measurements.

An event block object may be described as a grouping or package of eventobjects. An event stream may be described as a flow of event blockobjects. A continuous query of the one or more continuous queries 804transforms a source event stream made up of streaming event blockobjects published into ESPE 800 into one or more output event streamsusing the one or more source windows 806 and the one or more derivedwindows 808. A continuous query can also be thought of as data flowmodeling.

The one or more source windows 806 are at the top of the directed graphand have no windows feeding into them. Event streams are published intothe one or more source windows 806, and from there, the event streamsmay be directed to the next set of connected windows as defined by thedirected graph. The one or more derived windows 808 are all instantiatedwindows that are not source windows and that have other windowsstreaming events into them. The one or more derived windows 808 mayperform computations or transformations on the incoming event streams.The one or more derived windows 808 transform event streams based on thewindow type (that is operators such as join, filter, compute, aggregate,copy, pattern match, procedural, union, etc.) and window settings. Asevent streams are published into ESPE 800, they are continuouslyqueried, and the resulting sets of derived windows in these queries arecontinuously updated.

FIG. 9 is a flow chart of an example of a process including operationsperformed by an event stream processing engine according to someaspects. As noted, the ESPE 800 (or an associated ESP application)defines how input event streams are transformed into meaningful outputevent streams. More specifically, the ESP application may define howinput event streams from publishers (e.g., network devices providingsensed data) are transformed into meaningful output event streamsconsumed by subscribers (e.g., a data analytics project being executedby a machine or set of machines).

Within the application, a user may interact with one or more userinterface windows presented to the user in a display under control ofthe ESPE independently or through a browser application in an orderselectable by the user. For example, a user may execute an ESPapplication, which causes presentation of a first user interface window,which may include a plurality of menus and selectors such as drop downmenus, buttons, text boxes, hyperlinks, etc. associated with the ESPapplication as understood by a person of skill in the art. Variousoperations may be performed in parallel, for example, using a pluralityof threads.

At operation 900, an ESP application may define and start an ESPE,thereby instantiating an ESPE at a device, such as machine 220 and/or240. In an operation 902, the engine container is created. Forillustration, ESPE 800 may be instantiated using a function call thatspecifies the engine container as a manager for the model.

In an operation 904, the one or more continuous queries 804 areinstantiated by ESPE 800 as a model. The one or more continuous queries804 may be instantiated with a dedicated thread pool or pools thatgenerate updates as new events stream through ESPE 800. Forillustration, the one or more continuous queries 804 may be created tomodel business processing logic within ESPE 800, to predict eventswithin ESPE 800, to model a physical system within ESPE 800, to predictthe physical system state within ESPE 800, etc. For example, as noted,ESPE 800 may be used to support sensor data monitoring and management(e.g., sensing may include force, torque, load, strain, position,temperature, air pressure, fluid flow, chemical properties, resistance,electromagnetic fields, radiation, irradiance, proximity, acoustics,moisture, distance, speed, vibrations, acceleration, electricalpotential, or electrical current, etc.).

ESPE 800 may analyze and process events in motion or “event streams.”Instead of storing data and running queries against the stored data,ESPE 800 may store queries and stream data through them to allowcontinuous analysis of data as it is received. The one or more sourcewindows 806 and the one or more derived windows 808 may be created basedon the relational, pattern matching, and procedural algorithms thattransform the input event streams into the output event streams tomodel, simulate, score, test, predict, etc. based on the continuousquery model defined and application to the streamed data.

In an operation 906, a publish/subscribe (pub/sub) capability isinitialized for ESPE 800. In an illustrative embodiment, a pub/subcapability is initialized for each project of the one or more projects802. To initialize and enable pub/sub capability for ESPE 800, a portnumber may be provided. Pub/sub clients can use a host name of an ESPdevice running the ESPE and the port number to establish pub/subconnections to ESPE 800.

FIG. 10 is a block diagram of an ESP system 1000 interfacing betweenpublishing device 1022 and event subscription devices 1024 a-c accordingto some aspects. ESP system 1000 may include ESP subsystem 1001,publishing device 1022, an event subscription device A 1024 a, an eventsubscription device B 1024 b, and an event subscription device C 1024 c.Input event streams are output to ESP subsystem 1001 by publishingdevice 1022. In alternative embodiments, the input event streams may becreated by a plurality of publishing devices. The plurality ofpublishing devices further may publish event streams to other ESPdevices. The one or more continuous queries instantiated by ESPE 800 mayanalyze and process the input event streams to form output event streamsoutput to event subscription device A 1024 a, event subscription deviceB 1024 b, and event subscription device C 1024 c. ESP system 1000 mayinclude a greater or a fewer number of event subscription devices ofevent subscription devices.

Publish-subscribe is a message-oriented interaction paradigm based onindirect addressing. Processed data recipients specify their interest inreceiving information from ESPE 800 by subscribing to specific classesof events, while information sources publish events to ESPE 800 withoutdirectly addressing the receiving parties. ESPE 800 coordinates theinteractions and processes the data. In some cases, the data sourcereceives confirmation that the published information has been receivedby a data recipient.

A publish/subscribe API may be described as a library that enables anevent publisher, such as publishing device 1022, to publish eventstreams into ESPE 800 or an event subscriber, such as event subscriptiondevice A 1024 a, event subscription device B 1024 b, and eventsubscription device C 1024 c, to subscribe to event streams from ESPE800. For illustration, one or more publish/subscribe APIs may bedefined. Using the publish/subscribe API, an event publishingapplication may publish event streams into a running event streamprocessor project source window of ESPE 800, and the event subscriptionapplication may subscribe to an event stream processor project sourcewindow of ESPE 800.

The publish/subscribe API provides cross-platform connectivity andendianness compatibility between ESP application and other networkedapplications, such as event publishing applications instantiated atpublishing device 1022, and event subscription applications instantiatedat one or more of event subscription device A 1024 a, event subscriptiondevice B 1024 b, and event subscription device C 1024 c.

Referring back to FIG. 9, operation 906 initializes thepublish/subscribe capability of ESPE 800. In an operation 908, the oneor more projects 802 are started. The one or more started projects mayrun in the background on an ESP device. In an operation 910, an eventblock object is received from one or more computing device of thepublishing device 1022.

ESP subsystem 1001 may include a publishing client 1002, ESPE 800, asubscribing client A 1004, a subscribing client B 1006, and asubscribing client C 1008. Publishing client 1002 may be started by anevent publishing application executing at publishing device 1022 usingthe publish/subscribe API. Subscribing client A 1004 may be started byan event subscription application A, executing at event subscriptiondevice A 1024 a using the publish/subscribe API. Subscribing client B1006 may be started by an event subscription application B executing atevent subscription device B 1024 b using the publish/subscribe API.Subscribing client C 1008 may be started by an event subscriptionapplication C executing at event subscription device C 1024 c using thepublish/subscribe API.

An event block object containing one or more event objects is injectedinto a source window of the one or more source windows 806 from aninstance of an event publishing application on publishing device 1022.The event block object may be generated, for example, by the eventpublishing application and may be received by publishing client 1002. Aunique ID may be maintained as the event block object is passed betweenthe one or more source windows 806 and/or the one or more derivedwindows 808 of ESPE 800, and to subscribing client A 1004, subscribingclient B 1006, and subscribing client C 1008 and to event subscriptiondevice A 1024 a, event subscription device B 1024 b, and eventsubscription device C 1024 c. Publishing client 1002 may furthergenerate and include a unique embedded transaction ID in the event blockobject as the event block object is processed by a continuous query, aswell as the unique ID that publishing device 1022 assigned to the eventblock object.

In an operation 912, the event block object is processed through the oneor more continuous queries 804. In an operation 914, the processed eventblock object is output to one or more computing devices of the eventsubscription devices 1024 a-c. For example, subscribing client A 1004,subscribing client B 1006, and subscribing client C 1008 may send thereceived event block object to event subscription device A 1024 a, eventsubscription device B 1024 b, and event subscription device C 1024 c,respectively.

ESPE 800 maintains the event block containership aspect of the receivedevent blocks from when the event block is published into a source windowand works its way through the directed graph defined by the one or morecontinuous queries 804 with the various event translations before beingoutput to subscribers. Subscribers can correlate a group of subscribedevents back to a group of published events by comparing the unique ID ofthe event block object that a publisher, such as publishing device 1022,attached to the event block object with the event block ID received bythe subscriber.

In an operation 916, a determination is made concerning whether or notprocessing is stopped. If processing is not stopped, processingcontinues in operation 910 to continue receiving the one or more eventstreams containing event block objects from the, for example, one ormore network devices. If processing is stopped, processing continues inan operation 918. In operation 918, the started projects are stopped. Inoperation 920, the ESPE is shutdown.

As noted, in some examples, big data is processed for an analyticsproject after the data is received and stored. In other examples,distributed applications process continuously flowing data in real-timefrom distributed sources by applying queries to the data beforedistributing the data to geographically distributed recipients. Asnoted, an event stream processing engine (ESPE) may continuously applythe queries to the data as it is received and determines which entitiesreceive the processed data. This allows for large amounts of data beingreceived and/or collected in a variety of environments to be processedand distributed in real time. For example, as shown with respect to FIG.2, data may be collected from network devices that may include deviceswithin the internet of things, such as devices within a home automationnetwork. However, such data may be collected from a variety of differentresources in a variety of different environments. In any such situation,embodiments of the present technology allow for real-time processing ofsuch data.

Aspects of the present disclosure provide technical solutions totechnical problems, such as computing problems that arise when an ESPdevice fails which results in a complete service interruption andpotentially significant data loss. The data loss can be catastrophicwhen the streamed data is supporting mission critical operations, suchas those in support of an ongoing manufacturing or drilling operation.An example of an ESP system achieves a rapid and seamless failover ofESPE running at the plurality of ESP devices without serviceinterruption or data loss, thus significantly improving the reliabilityof an operational system that relies on the live or real-time processingof the data streams. The event publishing systems, the event subscribingsystems, and each ESPE not executing at a failed ESP device are notaware of or effected by the failed ESP device. The ESP system mayinclude thousands of event publishing systems and event subscribingsystems. The ESP system keeps the failover logic and awareness withinthe boundaries of out-messaging network connector and out-messagingnetwork device.

In one example embodiment, a system is provided to support a failoverwhen event stream processing (ESP) event blocks. The system includes,but is not limited to, an out-messaging network device and a computingdevice. The computing device includes, but is not limited to, one ormore processors and one or more computer-readable mediums operablycoupled to the one or more processor. The processor is configured toexecute an ESP engine (ESPE). The computer-readable medium hasinstructions stored thereon that, when executed by the processor, causethe computing device to support the failover. An event block object isreceived from the ESPE that includes a unique identifier. A first statusof the computing device as active or standby is determined. When thefirst status is active, a second status of the computing device as newlyactive or not newly active is determined. Newly active is determinedwhen the computing device is switched from a standby status to an activestatus. When the second status is newly active, a last published eventblock object identifier that uniquely identifies a last published eventblock object is determined. A next event block object is selected from anon-transitory computer-readable medium accessible by the computingdevice. The next event block object has an event block object identifierthat is greater than the determined last published event block objectidentifier. The selected next event block object is published to anout-messaging network device. When the second status of the computingdevice is not newly active, the received event block object is publishedto the out-messaging network device. When the first status of thecomputing device is standby, the received event block object is storedin the non-transitory computer-readable medium.

FIG. 11 is a flow chart of an example of a process for generating andusing a machine-learning model according to some aspects. Machinelearning is a branch of artificial intelligence that relates tomathematical models that can learn from, categorize, and makepredictions about data. Such mathematical models, which can be referredto as machine-learning models, can classify input data among two or moreclasses; cluster input data among two or more groups; predict a resultbased on input data; identify patterns or trends in input data; identifya distribution of input data in a space; or any combination of these.Examples of machine-learning models can include (i) neural networks;(ii) decision trees, such as classification trees and regression trees;(iii) classifiers, such as naïve bias classifiers, logistic regressionclassifiers, ridge regression classifiers, random forest classifiers,least absolute shrinkage and selector (LASSO) classifiers, and supportvector machines; (iv) clusterers, such as k-means clusterers, mean-shiftclusterers, and spectral clusterers; (v) factorizers, such asfactorization machines, principal component analyzers and kernelprincipal component analyzers; and (vi) ensembles or other combinationsof machine-learning models. In some examples, neural networks caninclude deep neural networks, feed-forward neural networks, recurrentneural networks, convolutional neural networks, radial basis function(RBF) neural networks, echo state neural networks, long short-termmemory neural networks, bi-directional recurrent neural networks, gatedneural networks, hierarchical recurrent neural networks, stochasticneural networks, modular neural networks, spiking neural networks,dynamic neural networks, cascading neural networks, neuro-fuzzy neuralnetworks, or any combination of these.

Different machine-learning models may be used interchangeably to performa task. Examples of tasks that can be performed at least partially usingmachine-learning models include various types of scoring;bioinformatics; cheminformatics; software engineering; fraud detection;customer segmentation; generating online recommendations; adaptivewebsites; determining customer lifetime value; search engines; placingadvertisements in real time or near real time; classifying DNAsequences; affective computing; performing natural language processingand understanding; object recognition and computer vision; roboticlocomotion; playing games; optimization and metaheuristics; detectingnetwork intrusions; medical diagnosis and monitoring; or predicting whenan asset, such as a machine, will need maintenance.

Any number and combination of tools can be used to createmachine-learning models. Examples of tools for creating and usingmachine-learning models can include SAS Enterprise Miner (e.g., with theSAS Text Miner add-on), SAS Rapid Predictive Modeler, SAS Model Manager,SAS Cloud Analytic Services (CAS), and SAS Viya (e.g., including VisualText Analytics and Visual Analytics), all of which are by SAS InstituteInc.® of Cary, N.C.

Machine-learning models can be constructed through an at least partiallyautomated (e.g., with little or no human involvement) process calledtraining. During training, input data can be iteratively supplied to amachine-learning model to enable the machine-learning model to identifypatterns related to the input data or to identify relationships betweenthe input data and output data. With training, the machine-learningmodel can be transformed from an untrained state to a trained state.Input data can be split into one or more training sets and one or morevalidation sets, and the training process may be repeated multipletimes. The splitting may follow a k-fold cross-validation rule, aleave-one-out-rule, a leave-p-out rule, or a holdout rule. An overviewof training and using a machine-learning model is described below withrespect to the flow chart of FIG. 11.

In block 1104, training data is received. In some examples, the trainingdata is received from a remote database or a local database, constructedfrom various subsets of data, or input by a user. The training data canbe used in its raw form for training a machine-learning model orpre-processed into another form, which can then be used for training themachine-learning model. For example, the raw form of the training datacan be smoothed, truncated, aggregated, clustered, or otherwisemanipulated into another form, which can then be used for training themachine-learning model.

In block 1106, a machine-learning model is trained using the trainingdata. The machine-learning model can be trained in a supervised,unsupervised, or semi-supervised manner. In supervised training, eachinput in the training data is correlated to a desired output. Thisdesired output may be a scalar, a vector, or a different type of datastructure such as text or an image. This may enable the machine-learningmodel to learn a mapping between the inputs and desired outputs. Inunsupervised training, the training data includes inputs, but notdesired outputs, so that the machine-learning model has to findstructure in the inputs on its own. In semi-supervised training, onlysome of the inputs in the training data are correlated to desiredoutputs.

In block 1108, the machine-learning model is evaluated. An evaluationdataset can be obtained, for example, via user input or from a database.The evaluation dataset can include inputs correlated to desired outputs.The inputs can be provided to the machine-learning model and the outputsfrom the machine-learning model can be compared to the desired outputs.If the outputs from the machine-learning model closely correspond withthe desired outputs, the machine-learning model may have a high degreeof accuracy. For example, if 90% or more of the outputs from themachine-learning model are the same as the desired outputs in theevaluation dataset, the machine-learning model may have a high degree ofaccuracy. Otherwise, the machine-learning model may have a low degree ofaccuracy. The 90% number is an example only. A realistic and desirableaccuracy percentage is dependent on the problem and the data.

In some examples, if the machine-learning model has an inadequate degreeof accuracy for a particular task, the process can return to block 1106,where the machine-learning model can be further trained using additionaltraining data or otherwise modified to improve accuracy. If themachine-learning model has an adequate degree of accuracy for theparticular task, the process can continue to block 1110.

In block 1110, new data is received. In some examples, the new data isreceived from a remote database or a local database, constructed fromvarious subsets of data, or input by a user. The new data may be unknownto the machine-learning model. For example, the machine-learning modelmay not have previously processed or analyzed the new data.

In block 1112, the trained machine-learning model is used to analyze thenew data and provide a result. For example, the new data can be providedas input to the trained machine-learning model. The trainedmachine-learning model can analyze the new data and provide a resultthat includes a classification of the new data into a particular class,a clustering of the new data into a particular group, a prediction basedon the new data, or any combination of these.

In block 1114, the result is post-processed. For example, the result canbe added to, multiplied with, or otherwise combined with other data aspart of a job. As another example, the result can be transformed from afirst format, such as a time series format, into another format, such asa count series format. Any number and combination of operations can beperformed on the result during post-processing.

A more specific example of a machine-learning model is the neuralnetwork 1200 shown in FIG. 12. The neural network 1200 is represented asmultiple layers of interconnected neurons, such as neuron 1208, that canexchange data between one another. The layers include an input layer1202 for receiving input data, a hidden layer 1204, and an output layer1206 for providing a result. The hidden layer 1204 is referred to ashidden because it may not be directly observable or have its inputdirectly accessible during the normal functioning of the neural network1200. Although the neural network 1200 is shown as having a specificnumber of layers and neurons for exemplary purposes, the neural network1200 can have any number and combination of layers, and each layer canhave any number and combination of neurons.

The neurons and connections between the neurons can have numericweights, which can be tuned during training. For example, training datacan be provided to the input layer 1202 of the neural network 1200, andthe neural network 1200 can use the training data to tune one or morenumeric weights of the neural network 1200. In some examples, the neuralnetwork 1200 can be trained using backpropagation. Backpropagation caninclude determining a gradient of a particular numeric weight based on adifference between an actual output of the neural network 1200 and adesired output of the neural network 1200. Based on the gradient, one ormore numeric weights of the neural network 1200 can be updated to reducethe difference, thereby increasing the accuracy of the neural network1200. This process can be repeated multiple times to train the neuralnetwork 1200. For example, this process can be repeated hundreds orthousands of times to train the neural network 1200.

In some examples, the neural network 1200 is a feed-forward neuralnetwork. In a feed-forward neural network, every neuron only propagatesan output value to a subsequent layer of the neural network 1200. Forexample, data may only move one direction (forward) from one neuron tothe next neuron in a feed-forward neural network.

In other examples, the neural network 1200 is a recurrent neuralnetwork. A recurrent neural network can include one or more feedbackloops, allowing data to propagate in both forward and backward throughthe neural network 1200. This can allow for information to persistwithin the neural network. For example, a recurrent neural network candetermine an output based at least partially on information that therecurrent neural network has seen before, giving the recurrent neuralnetwork the ability to use previous input to inform the output.

In some examples, the neural network 1200 operates by receiving a vectorof numbers from one layer; transforming the vector of numbers into a newvector of numbers using a matrix of numeric weights, a nonlinearity, orboth; and providing the new vector of numbers to a subsequent layer ofthe neural network 1200. Each subsequent layer of the neural network1200 can repeat this process until the neural network 1200 outputs afinal result at the output layer 1206. For example, the neural network1200 can receive a vector of numbers as an input at the input layer1202. The neural network 1200 can multiply the vector of numbers by amatrix of numeric weights to determine a weighted vector. The matrix ofnumeric weights can be tuned during the training of the neural network1200. The neural network 1200 can transform the weighted vector using anonlinearity, such as a sigmoid tangent or the hyperbolic tangent. Insome examples, the nonlinearity can include a rectified linear unit,which can be expressed using the following equation:y=max(x,0)where y is the output and x is an input value from the weighted vector.The transformed output can be supplied to a subsequent layer, such asthe hidden layer 1204, of the neural network 1200. The subsequent layerof the neural network 1200 can receive the transformed output, multiplythe transformed output by a matrix of numeric weights and anonlinearity, and provide the result to yet another layer of the neuralnetwork 1200. This process continues until the neural network 1200outputs a final result at the output layer 1206.

Other examples of the present disclosure may include any number andcombination of machine-learning models having any number and combinationof characteristics. The machine-learning model(s) can be trained in asupervised, semi-supervised, or unsupervised manner, or any combinationof these. The machine-learning model(s) can be implemented using asingle computing device or multiple computing devices, such as thecommunications grid computing system 400 discussed above.

Implementing some examples of the present disclosure at least in part byusing machine-learning models can reduce the total number of processingiterations, time, memory, electrical power, or any combination of theseconsumed by a computing device when analyzing data. For example, aneural network may more readily identify patterns in data than otherapproaches. This may enable the neural network to analyze the data usingfewer processing cycles and less memory than other approaches, whileobtaining a similar or greater level of accuracy.

Some machine-learning approaches may be more efficiently and quicklyexecuted and processed with machine-learning specific processors (e.g.,not a generic CPU). Such processors may also provide an energy savingswhen compared to generic CPUs. For example, some of these processors caninclude a graphical processing unit (GPU), an application-specificintegrated circuit (ASIC), a field-programmable gate array (FPGA), anartificial intelligence (AI) accelerator, a neural computing core, aneural computing engine, a neural processing unit, a purpose-built chiparchitecture for deep learning, and/or some other machine-learningspecific processor that implements a machine learning approach or one ormore neural networks using semiconductor (e.g., silicon (Si), galliumarsenide (GaAs)) devices. Furthermore, these processors may also beemployed in heterogeneous computing architectures with a number of and avariety of different types of cores, engines, nodes, and/or layers toachieve various energy efficiencies, thermal processing mitigation,processing speed improvements, data communication speed improvements,and/or data efficiency targets and improvements throughout various partsof the system when compared to a homogeneous computing architecture thatemploys CPUs for general purpose computing.

FIG. 13 is a flow chart of an example of a process executable by aprocessor according to some aspects. Although the flow chart shows aspecific number and sequence of operations, this is not intended to belimiting. Other examples may involve more operations, fewer operations,different operations, or a different order of the operations than isshown in FIG. 13.

In block 1300, the processor generates and outputs a graphical userinterface through which a user can select a target textual dataset toundergo subsequent analysis. In some examples, the user may also be ableto select a reference textual dataset through the graphical userinterface. Alternatively, the reference textual dataset may be preset bydefault.

In block 1302, the processor analyzes the reference textual dataset togenerate a first text profile including a first set of metrics. In someexamples, the processor can analyze the textual dataset usingtext-mining techniques, such as natural language processing (NLP)techniques, to generate the metrics in the text profile. In someexamples, the text-mining techniques can perform tokenization,sentence-boundary detection, contraction normalization, multiwordanalysis, token-type identification and categorization, pronounclassification, clause analysis, dictionary analysis (e.g., to identifyknown words) and lemmatization (morphological analysis), genrecategorization, dependency parsing, grammatical-pattern identification,misspelling analysis, topic analysis, or any combination of these.

One metric that can be included in the first set of metrics can be thenumber of languages (e.g., English, Spanish, and French would be threelanguages) or dialects that are present in the target textual dataset.To compute this metric, algorithms for language identification ordialect identification can be applied. For example, a processor may useexecute an algorithm that relies on dialect-specific orlanguage-specific keywords to identify languages in the referencetextual dataset. The linguistic variation across datasets from differentlanguages is likely to be very high. Other examples of metrics can befound in the following table.

TABLE 1 Example Metrics Type Description int64 Total number of functionwords in the dataset. float Percentage of uppercase to lowercaseletters. int64 Number of sentences in the longest document by sentencecount. float Average number of tokens per sentence. int64 Number oftokens in the longest sentence by token count. int64 Total number ofunique words in the dataset. float Average number of characters (orbytes for some languages) per token (all non-unique tokens counted).int64 Number of characters/bytes in the longest token. int64 Number ofunique tokens in the dataset. int64 Number of forms (unique tokens) toaccount for 80% of the data. float Percentage of tokens that are contentwords (not numeric or stop words and not punctuations). float Percentageof tokens in the dataset that are stop words. float Percentage of tokenswith a number/digit in them. float Percentage of tokens that arepunctuations.

In above table, the column on the left side indicates the data formatsof the metrics, such as string, integer in 64 bit format, and floatnumber. The column on the right side of the table provides descriptionsof the metrics. Note that the above examples of data formats and metricsare intended to be illustrative and non-limiting.

Other types of data formats and metrics may also be used. Some of theseother examples of metrics are described in greater detail later on withreference to FIG. 15. These metrics may generally fall into thecategories of vocabulary diversity, information density, languageformality, information complexity, and domain specificity.

In block 1304, the processor analyzes a target textual dataset togenerate a second text profile and second set of metrics. The second setof metrics can include any of the metrics described herein. Any of theprocesses described herein may be executed to determine the second setof metrics for the target textual dataset.

In block 1306, the processor determines a similarity value by comparingat least some of the first and second metrics. The similarity value is aquantitative indicator that represents how similar the target textualdataset is to the reference textual dataset by comparing the second textprofile to the first text profile. Comparing the second text profile tothe first text profile may involve comparing at least some of the secondset of metrics to at least some of the first set of metrics. In someexamples, each metric in the first set of metrics can be comparedseparately to each metric in the second set of metrics. The followingparagraphs describe some examples of processes for determining asimilarity value corresponding to the reference and target textualdatasets.

Datasets can be compared based on some or all of the metrics discussedherein to compute a similarity value. One similarity value that can becomputed based on these metrics is the Jensen-Shannondivergence/difference. Other similarity values may also be used insteadof, or in combination with, Jensen-Shannon to determine the similaritybetween textual datasets (e.g., corpora). Examples of such similarityvalues can include Euclidean distance, Manhattan distance, Cosinedistance, Chi-square, Spearman's rho (p), Jaccard similaritycalculation, nearest neighbor vocabulary or topic comparisons, or anycombination of these.

An example of using Jensen-Shannon difference on the document-lengthmetric (e.g., as determined by the sentence count-per-document) will nowbe described. Looking at the metrics for sentences-per-document acrossfour English data sets yields a Jensen-Shannon distance chart like thebar chart 2020 shown in FIG. 20. A higher distance value indicates thatthe two textual datasets are less similar than a lower distance value.From the bar chart 2020, it is apparent that the most similar datasetswith respect to document length are the Amazon® and airline datasets, asshown by bar 2004. The most different datasets are the parks and airlinedatasets, as shown by bar 2002. One interpretation of this data is thatmodels, which rely on document length or are sensitive to differentdocument lengths in the data, will be at more risk of poor accuracy oraccuracy loss when applied to such datasets.

Another example may involve using the proportions of uppercase lettersto lowercase letters in the textual datasets as a basis for determiningtheir similarity. The proportions of uppercase letters to lowercaseletters can indicate how formal the textual dataset is. To compute thesemetrics for the textual datasets, the processor can compute theproportions of uppercase letters to lowercase letters in each textualdataset. The proportion of uppercase letters to lowercase letters in agiven textual dataset can be converted into a percentage value for thatdataset. The percentage value can serve as one of the metrics in thetextual profile for that dataset. Next, the processor can compare thetwo metrics for each textual dataset by computing a ratio of the twometrics, where one of the metrics will have a smaller percentage valueand the other metric will have a larger percentage value. In this way,the ratio can be represented as a percentage value or a number between 0to 1. A larger ratio number can indicate the reference textual datasetand the target textual dataset have similar language formality. Asmaller ratio number can indicate the reference textual dataset and thetarget textual dataset have less similar language formality. The ratiomay be, or may be used as a factor to compute, a similarity value.

Another example may involve using the number of unique words in thetextual datasets as a basis for determining their similarity. The numberof unique words can indicate the degree of vocabulary diversity in thetextual dataset. To compute these metrics for the textual datasets, theprocessor can compute the number of unique words in each textualdataset. The number of unique words in a given textual dataset can beconverted into a percentage value by dividing the total number of wordsin the textual dataset by the number of unique words in the textualdataset. Next, the processor can compare the two metrics for eachtextual dataset by computing a ratio of the two metrics, with the one ofthe metrics having a smaller percentage value and the other metrichaving a larger percentage value. In this way, the ratio can berepresented as a percentage value or a number between 0 to 1. A largerratio number can indicate the reference textual dataset and the targettextual dataset have a similar amount of vocabulary diversity. A smallerratio number can indicate the reference textual dataset and the targettextual dataset have less similar amounts of vocabulary diversity. Theratio may be, or may be used as a factor to compute, a similarity value.

Another example may involve using the number of function words in thetextual datasets as a basis for determining their similarity. Ingeneral, content words carry the most meaning in a document, and thefunction words are used to highlight relationships and situate thatmeaning in context. Thus, a higher number of function words over contentwords can indicate a lower level of information density. To computethese metrics for the textual datasets, the processor can compute thenumber of function words in each textual dataset. The number of functionwords in a given textual dataset can be converted into a percentagevalue by dividing the total number of words in the textual dataset bythe number of function words in the textual dataset. Next, the processorcan compare the two metrics in each textual dataset by computing a ratioof the two metrics, where one of the metrics will have a smallerpercentage value and the other metric will have a larger percentagevalue. In this way, the ratio can be represented as a percentage valueor a number between 0 to 1. A larger ratio number can indicate thereference textual dataset and the target textual dataset have similarlevels of information density. A smaller ratio number can indicate thereference textual dataset and the target textual dataset have lesssimilar levels of information density. The ratio may be, or may be usedas a factor to compute, a similarity value.

Other metrics can be compared to one another, additionally oralternatively to the ones described above, to determine how similar anddissimilar the target textual dataset is to the reference textualdataset. And while the above similarity values are represented as ratiosor percentages, in other examples the similarity values may berepresented as other types of numerical values.

Some or all of the similarity information can be used to generate asingle similarity value or a similarity profile. For example, analgorithm may be applied to the above ratios to compute a singlesimilarity value. The algorithm may combine (e.g., aggregate) togetherall of the individual ratios into a single similarity value. In otherexamples, the similarity values may be incorporated into a similarityprofile (e.g., a profile that contains the multiple similarity values)representing the similarity between the target textual dataset and thereference textual dataset.

Some or all of the similarity value can be used to generate a singlesimilarity value or a similarity profile through a weighting algorithm.The weighting algorithm can be used to weight the similarity value orthe similarity profile that was calculated based on a various factors ormetrics described above, such as document-length, number of uniquewords, and number of function words. In some examples, the similarityvalue or the similarity profile can be weighted by multiplying aweighting value through the weighting algorithm based on the importanceof the similarity value or the similarity profile. For example, ifdocument length is considered relatively less important among allmetrics or to a specific model, then the similarity value or thesimilarity profile can be decreased by multiplying it by a weightingfactor between 0 to 1. Conversely, if document length is consideredrelatively more important among all metrics or to a specific model, thenthe similarity value or the similarity profile can be increased bymultiplying it by a weighting factor larger than 1.

In some examples, the Jensen-Shannon difference value can be normalizedto make the comparison result between different datasets more apparent.To normalize the Jensen-Shannon difference value, a Jensen-Shannondifference associated with a certain type metric between datasets can bedivided by the highest Jensen-Shannon difference value. The normalizedJensen-Shannon difference value will then be a numerical value between 0to 1. If the normalized Jensen-Shannon difference is closer to 1, thenthe two different datasets may be relatively different to one another.And if the normalized Jensen-Shannon difference is closer to 0, then thetwo different datasets may be relatively similar to one another.

An example of using normalized Jensen-Shannon differences with respectto four metric types (e.g., normalized document length difference,normalized sentence length difference, normalized word lengthdifference, and normalized word category) will now be described. Lookingat the four metrics for across four English data sets yields aJensen-Shannon distance chart like the bar chart 2100 shown in FIG. 21.A higher normalized distance value indicates that the two textualdatasets are less similar than a lower distance value. From the barchart 2100, it is apparent that the most similar datasets with respectto document length are the Amazon® and airline datasets, as shown by bar2104. The most different datasets are the parks and airline datasets, asshown by bar 2102. After comparing the four metrics across the fourdatasets in FIG. 21, an appropriate model can be selected based onconsiderations of risk level and expected accuracy loss. For example, amodel trained on the Amazon® dataset may suitable for use with theairline dataset because the four types of metrics show high similaritybetween those datasets. In contrast, a model trained on the parksdataset may not suitable for use with the airline dataset because thefour types of metrics show low similarity between those datasets.

More metrics can be used to compare two datasets to provide more datapoints about their similarities and differences. In order to make thecomparison results more apparent, the manner described above regardingnormalizing Jensen-Shannon difference can be employed. One such exampleis shown in FIG. 22. This example shows the comparison result 2200 offour different normalized metrics used to determine similarities betweendatasets Casino and Amazon®. The four different normalized metrics 2202are listed along the Y-axis and include normalized word categorydifference (WordC Dist Norm), normalized word length difference (WordLDist Norm), normalized sentence length difference (Sent Dist Norm), andnormalized document length difference (Doc Dist Norm). The X-axis 2504shows similarity scores. The word category metric and the word lengthmetric indicate that the two datasets are very similar, given that theirsimilarity scores are closer to zero. The sentence length and documentlength metrics are both moderately different, falling towards the middleof the difference range.

FIG. 23 shows an example of a histogram 2300 of raw counts associatedwith a word length metric in relation to the Casino and Amazon®datasets. An example of a histogram 2400 in which the raw counts of FIG.23 are normalized using percentages is shown in FIG. 24. Comparing thetwo histograms, the size of the bars is slightly different between thetwo but the overall shapes are similar. Normalizing the metric valuesmay therefore impact the sizes of the values, but the overall shapes andprofiles relating to the metric values may remain the similar andtherefore usable as a basis of comparison between datasets.

Another example is shown in FIG. 25. In this figure, a bar chart 2500 isused to show a comparison between four different normalized metrics 1502usable to determine similarities between two datasets, including sleepabstracts and automotive technical notes. The four different normalizedmetrics 2502 are listed along the Y-axis and include normalized wordcategory difference (WordC Dist Norm), normalized word length difference(WordL Dist Norm), normalized sentence length difference (Sent DistNorm), and normalized document length difference (Doc Dist Norm). TheX-axis 2504 shows similarity scores. Note that the normalized wordcategory difference is moderately different between the two datasets andthe other three metrics basis are very different. This comparison resultshows that it might be risky to use a model trained on automotivetechnical notes to analyze sleep abstracts, or vice versa.

Another example is shown in FIG. 26. In this figure, a bar chart 2600 isused to show a comparison between four different normalized metricsusable to determine similarities between two datasets, includingautomotive technical notes and park datasets. The four differentnormalized metrics 2602 are listed along the Y-axis and includenormalized word category difference (WordC Dist Norm), normalized wordlength difference (WordL Dist Norm), normalized sentence lengthdifference (Sent Dist Norm), and normalized document length difference(Doc Dist Norm). The X-axis 2604 shows similarity scores. In thiscomparison, the similarity score for the normalized word category metricis very different between the two datasets. This might indicate that theuse of stop words is miserly compared with typical datasets, while theuse of numeric words is a bit higher in the automotive technical notes.

In block 1308, the processor receives a selection of a model from theuser via the graphical user interface. For example, the user may be ableto select a specific model or model type from a list of candidates usinga pulldown menu in the graphical user interface. Examples of thecandidates can include a rules-based model such as thelanguage-interpretation and text-interpretation (LITI) model by SASInstitute® of Cary, N.C.; a rule-based/hybrid model such as thecategorization model by SAS Institute®; a recurrent neural network(RNN); a conditional random fields (CRF) model; a bidirectional encoderrepresentations from transformers (BERT) model; or any combination ofthese. The processor can receive this selection for use in subsequentoperations.

In block 1310, the processor can determine characteristics of the model(e.g., the specific model or model type) selected by the user. Examplesof the characteristics can include a type of the model, a setting of themodel, or a setting value of the model (e.g., a hyperparameter value ofthe model). In some examples, the processor can determine thecharacteristics by accessing a predefined database that includesrelationships between models and their characteristics. Additionally oralternatively, the processor can determine the characteristics byaccessing configuration information, such as configuration data storedin a configuration file, for the model. The configuration informationmay specify the characteristics. For example, the configurationinformation may specify the settings and setting values applied to themodel.

In block 1312, the processor can generate one or more insights based onthe similarity value and the characteristics of the model. In someexamples, the similarity value and the characteristics of the model canbe interpreted using one or more insight algorithms to produce someinsights about how well the model may function if it is applied to thetarget textual dataset. The insight algorithms can rely on statisticalmeasurements, the model type, the strengths/weaknesses of the model, thesettings of the model, or any combination of these, to generate the oneor more insights.

For example, if the similarity value is above a predefined threshold,such as 95% or 95 in a scale from 0 to 100, that means the targettextual dataset may be relatively similar to the reference textualdataset in relation to the one or more corresponding types of metricsbeing compared (e.g., language formality, vocabulary diversity,information density, etc.). Given this similarity, it may be areasonable conclusion that a model that operates relatively well on thereference textual dataset, or that was trained using the referencetextual dataset, will likely operate similarly well on the targettextual dataset. So, the processor can generate an insight indicatingthat the selected model will likely perform well on the target textualdataset.

When the similarity value indicates a significant difference between thetarget reference textual and the reference textual dataset, theprocessor then can further analyze the characteristics of the model tosuggest how to use the model on the target textual dataset. For example,the processor can provide guidance on how to adjust the settings of themodel to obtain optimal modeling results when the model is applied tothe target textual dataset. Alternatively, the processor can recommendusing an alternative type of model to achieve better (e.g., the best)modeling results. These processes are described in greater detail lateron with respect to FIG. 19.

Some examples described herein can compute various metrics and combinethem together to generate advice and strategies for model development,testing, or parameter settings. For example, two datasets (Corpus A andCorpus B) can be analyzed to compute various metrics. The followingtable lists metrics for Corpus B, which can form some or all of atextual profile for Corpus B. These metrics can then be assessed todetermine the impact on model accuracy.

TABLE 2 Metrics and corresponding meanings and model impacts Model TypeMetric Value Metric Meaning Impact VD Coverage-rank 0.63 How varied theHigh distribution vocabulary is in the data VD Vocabulary 30% How muchoverlap in High overlap vocabulary is there in the data VD Vocabulary0.49 How different is the High difference vocabulary in the data ID Wordlength 0.12 What length of words Low distribution appear in the data IDWord type ratio 0.30 Content words vs. other Moderate types of words IDUniqueness ratio 25% How much duplication is Moderate present in thedata LF First person .05 How much informality is Low pronoun ratiopresent in the data LF Unknown words .62 How much error may be Highratio in data IC Tokens per .12 How much info per Low sentence dist.sentence IC Sentences per .42 How much info per Moderate doc dist.document DS Token type ratio 30% How likely to be domain High specific

In the above table, “VD” stands for vocabulary diversity, “ID” standsfor information density, “LF” stands for language formality, and “DS”stands for document specificity. The impact of each metric's value onmodel accuracy is also shown. To determine each metric's accuracyimpact, each metric's value may be compared against one or morecorresponding thresholds. For example, the value for the coverage-rankdistribution metric may be compared against two thresholds. If thecoverage-rank distribution metric's is below a first threshold, it mayhave a low accuracy impact. If the coverage-rank distribution metric'sis above the first threshold and below a second threshold, it may have amoderate accuracy impact. If the coverage-rank distribution metric's isabove the second threshold, it may have a high accuracy impact. Asimilar process can be applied to the values of the other metrics listedin Table 2 to determine their accuracy impact, where each type of metriclist in Table 2 may have its own designated threshold or thresholds.More than two thresholds may be used for a greater level of granularity.It will be appreciated that while Table 2 represents the impact as low,moderate, or high, other ways of indicating the model impact could alsobe used, such as numerical values or letter grades.

Still referring to Table 2, a possible interpretation of the textualprofile for Corpus B is that the Corpus B is different from the sourcedataset (e.g., reference dataset) in a few important ways. First, thevocabulary is different, more varied, and does not overlap much with thesource corpus. Second, the probability that this is a domain-specificdataset is high based on the token-type ratio, number of unknown words(with lack of indicators of informality), and the amount of vocabularyoverlap. There are also some moderate differences in lengths of documentand use of content words and duplication rate. Overall, the likelihoodis high that the model will need some tuning to avoid a substantial lossof accuracy. In this example, the system could provide advice to theuser, such as to seek a corpus in the same domain or leverage thenon-overlapping terms list to seek new training data to use the furthertune the model. Additionally, the user could be advised to subdivide thetarget corpus to identify heterogeneous parts that should be evaluatedseparately during the tuning of the new model.

In block 1314, the processor can output the one or more insights in thegraphical user interface. The insights may take the form ofrecommendations, tips, comparisons, and/or guidance to assist the userin improving modeling results. In some examples, the processor canoutput the insights as graphs or charts in the graphical user interface.Additionally or alternatively, the processor can provide the insightsusing templates or a natural-language generation processes through whichthe insights can be provided in a human-language format to help the userbetter understand the insights. For example, the system can have apredefined set of templates, where each template can include a series ofsentences with blank fields that are filled in by the processor togenerate an insight. As another example, the system can include anatural-language generation model through which sentences can begenerated in a human-readable and digestible format based on a set ofinputs. The insight can indicate that the user should select analternative model, adjust settings of the model, test the model,preprocess the target textual dataset, or any combination of these.

In some examples, a user can select various models (e.g., specificmodels or model types) through the graphical user interface and run theabove processes to learn how the various models would perform on thetarget textual dataset. The processor can determine insights about howeach model would perform on the target textual dataset and output theinsights in the graphical user interface. In some cases, the insightsmay be presented in the form of an anticipated reduction in accuracy.One example of the graphical user interface with such insights is shownin FIG. 14. The graphical user interface includes a bar chart 1800indicating the predicted reduction in accuracy for different types ofmodels when the model types are applied to the target textual dataset.Along the Y-axis, “high” indicates more accuracy degradation than “low.”The user may review the insights and, in response to the insights,select a different model type or reconfigure their existing model type(e.g., update its parameters or settings) to obtain more accurateresults.

As noted above, the target textual dataset and the reference textualdataset can be analyzed to generate a respective set of metrics for eachdataset. There may be many categories (e.g., classes) of metrics capableof being determined. FIG. 15 depicts an example of categories of metricsaccording to some aspects. Each category of metrics can contain one ormore metrics. These are represented in box 1506 using the nomenclature(category, metric number), where for example (C1, M1) represents metric1 in category 1. Examples of the categories of metrics can includeinformation complexity, vocabulary diversity, information density,language formality, and domain specificity. The processor can computethe metrics in these categories by parsing through documents in thetextual datasets and aggregating counts of the metric values. Thesecategories will now be described in greater detail.

The information complexity category can indicate how much information ispacked into documents and sentences. Within the category of informationcomplexity can be several types of metrics that can be determined by theprocessor. Examples of those metrics can include the total number ofsentences in the textual dataset, the average number of tokens persentence, the minimum number of tokens per sentence, the maximum numberof tokens per sentence, the peak tokens per sentence, the total numberof documents in the corpus, the average number of sentences perdocument, the minimum number of sentences per document, and the maximumnumber of sentences per document.

Information complexity can be used to characterize the amount ofinformation in each document, sentence, or clause, therebycharacterizing the information load. Some examples can focus oninformation represented by the number of tokens per sentence or clause,the number of clauses per sentence, the depth of clauses per sentence,the number of sentences per documents, etc. While other research hasused some of these metrics, none has used them to characterize a dataset's complexity or to compare multiple datasets to one another. Someexamples of metrics that fall within the category of informationcomplexity are described below and can be obtained in multiple ways orin a combination of ways, including:

-   -   Statistics related to the number of tokens per sentence or        clause can be leveraged to compare the distributions between        data sets using a Jensen-Shannon difference/divergence score or        another similarity metric described above.    -   The proportion of sentences with n number of clauses can be        categorized and the distributions can be compared using a        similarity metric (e.g., Jensen-Shannon). The more clauses in a        sentence, the more complex it is.    -   The proportions of sentences with a clause depth of one, two,        three or more can be determined and used to indicate the        complexity within sentences. Sentences with deeper relationships        between clauses may be more difficult to understand and hold        more complex information. In some examples, the comparison may        performed in a way that is similar to the token-type proportions        mentioned above (e.g., Jensen-Shannon).    -   The number of sentences per document may also be an important        indication of the shape of the dataset. Categorizing documents        by their sentence number can create a distribution that can then        be compared through similarity metrics like Jensen-Shannon.    -   Other counts related to the structure of a document could also        be applied here, such as the number of paragraphs, the number of        titles, the number of chapters, the number of sections, etc.

Another category of linguistic information that can ascertained for agiven textual dataset can be vocabulary diversity. The vocabularydiversity category can indicate “lexical richness” in the textualdataset, such as the breadth of vocabulary and the amount of contentwords versus other types of tokens in the textual dataset. The moreunique words the textual dataset has, the more diverse the textualdataset is in terms of topics. Within the category of vocabularydiversity can be several types of metrics that can be determined by theprocessor. Examples of those metrics can include the total number ofunique tokens (forms) in the textual dataset, the total number ofpunctuation tokens in the textual dataset, the total number of uniquetokens that account for at least 80% of the data (e.g., a coveragemetric), and the total number of content words in the textual dataset.

Vocabulary diversity can be used to characterize the scope of thevocabulary and compare the datasets to one another. Some examples canfocus on content through word (type or form) frequency and distributioncomparisons, term-type ratios, vocabulary overlap, topic overlap, wordrepetition or concentration, word sophistication, etc. Some examples ofmetrics that fall within the category of vocabulary diversity aredescribed below and can be obtained in multiple ways or in a combinationof ways, including:

-   -   Following the coverage-rank distribution plot approach of Nemeth        and Zainko (2002) to represent the vocabulary of a dataset in a        way that can offset the difference in the size of multiple        datasets, so the representations can be compared.    -   A simpler way to measuring coverage that does not account for        the size of the dataset, by graphing the cumulative percentage        coverage from most-frequent word form to least-frequent word        form. This enables identification of where the vocabulary covers        a significant portion (80%) of the data.    -   Use of token-type ratios, leveraging the work by Temnikova et.        al. (2013), as a metric.    -   Determining a proportion of the terms in corpus B (the target        dataset) that overlap with corpus A (the reference dataset).    -   Evaluating distance between vocabulary through embeddings,        leveraging the work of Asgari et. al. (2016) to characterize the        distance between corpora using a joint similarity distribution        of words and calculating a Jensen-Shannon divergence (or        difference) between unified similarity distributions of the        datasets.    -   Leverage the chi-square approach of Babych et. al. (2014) to        compare vocabularies between two datasets. They were using the        comparison to select parallel corpora. This approach was also        used by Fothergill et. al. (2016) to compare a web corpus to a        reference corpus, but was the only metric they applied.    -   Leverage the methodology proposed by Kilgarrif (2001), who        compared chi-square and Spearman rank correlation for comparing        datasets based on vocabulary alone. This is the only metric        Kilgarrif used to make comparisons.    -   Leverage the Euclidean distance metric studied by Piperski        (2018).    -   Compare n-gram model perplexity from one dataset to another        using the approach described by Campos et. al. (2020). They were        using the approach to compare historical varieties of a language        or different languages for purposes of linguistic research.    -   Compare corpora based on word unigram frequencies or character        trigram frequencies leveraging the Spearman frequency-based        similarity measures used by Dunn (2021). He was using this to        answer the question of representativeness of a language variety        by different data sources to validate the use of such data in        linguistic research.    -   Measure word repetition rates like mean segmental type-token        ratio or measure of textual lexical diversity (related metrics)        using the approach represented by Jarvis (2013). His focus was        on measuring language proficiency.    -   Measuring concentration of categories within the population,        where terms are treated as categories using Yule's index or the        Gini-Simpson index.    -   Use cosine similarities based on the ranking lists of word        termhood, as described in the research by Liu et. al (2012), who        were interested in comparing corpora for the purpose of        bilingual terminology extraction.    -   Use any of the methods described above on bigrams or trigrams to        account for context of terms.    -   Extend the methods described above to topics as well as terms to        determine the distance between the datasets by comparing their        topics.    -   Measure vocabulary sophistication by scoring terms based upon        their frequency (in general datasets), range across the data set        (more sophisticated terms tend to appear in fewer documents),        and age of exposure rating or contextual distinctiveness        (semantic ambiguity) as described in Kyle et. al. (2017). Their        work focused on analyzing how advanced and fluent a written text        is based on vocabulary, not on comparison of datasets.

Another category of linguistic information that can ascertained for agiven textual dataset can be information density. The informationdensity category can be measured by the length of the words andproportion of content words. The longer the words and the higherproportion of content words in the textual dataset, the higher theinformation density in the textual dataset. Within the category ofinformation density can be several types of metrics that can bedetermined by the processor. Examples of those metrics can include theaverage length of words in the textual dataset, the minimum length ofthe words in the textual dataset, the maximum length of the words in thetextual dataset, the word length with the highest frequency (i.e., thatoccurs the most amount of times) in the textual dataset, the number ofunique words having each word length, and the number of words with themaximum word length.

Information density can be used to characterize the amount ofinformation that the words represent and compare the data sets to oneanother. Some example can focus on information represented by wordlength, word type, and perhaps metrics that highlight the specificity orsophistication of particular words. In addition to words, some examplescan identify duplication across documents, for example by leveraging theapproach of Baisa (2013) to distinguish repeated data from new data, orother methods may be used to identify the proportion of repeated data.Metrics related to information density have not been a focus of priorresearch for the purpose of comparing textual datasets. The priorresearch in this area has focused mainly on the readability of specifictexts. Some examples of metrics that fall within the category ofinformation density are described below and can be obtained in multipleways or in a combination of ways, including:

-   -   Comparing the distributions of word length in the datasets by        leveraging a similarity metric like Jensen-Shannon or        chi-square. Other possible similarity metrics include Euclidean        distance, Manhattan distance, Cosine distance, Chi-square,        Spearman's rho, nearest neighbor vocabulary or topic        comparisons, and Jaccard similarity calculation. The result can        represent word length difference between the datasets.    -   Comparing the distributions of the ratios of word type across        data sets through a similarity metric like Jensen-Shannon (or        one of the others mentioned above).    -   Comparing the distributions of the more or less        specific/sophisticated words in a similar manner.    -   Identifying the proportion of the data set that is duplicate        data, for example by using an n-gram approach like the one used        by Baisa (2013), to identify and count duplication. The datasets        can then be compared by using a similarity metric comparing the        proportions.

Another category of linguistic information that can ascertained for agiven textual dataset can be language formality. A higher proportion offirst-person pronouns in the textual dataset as compared with the totalnumber of stop words, the more informal the textual dataset is inclinedto be. Within the category of language formality can be several types ofmetrics that can be determined by the processor. Examples of thosemetrics can include a ratio of first-person pronouns to the total numberof stop words in the textual dataset.

Language formality can be used to characterize the patterns of standardwriting conventions, use of formal or informal constructions orvocabulary, and potential errors in the data. Markers of formal orinformal writing that can be measured include pronoun usage,contractions, slang, constructions like phrasal verbs and othergrammatical patterns of informal or formal use like passive verbs, useof uppercase and lowercase letters, proportion of punctuation tokens,proportion of spelling errors or unknown words, genre characterization,etc. Some examples of metrics that fall within the category of languageformality are described below and can be obtained in multiple ways or acombination of ways, including:

-   -   A proportion of the stop words that fit into specific categories        of formality, such as contractions or first or second person        pronouns. Chi-square or other similarity metric could be used to        compare across datasets.    -   Categorization of documents into genres and tracking of the        proportion of each genre across the data set. Comparisons of the        distributions of the genres across data sets might leverage        Jensen-Shannon differences/divergences or another similarity        metric.    -   Use of grammatical constructions that are markers of formality        for a given language, such as passive verbs or phrasal verbs in        English. This could be measured as a proportion of verbs in the        data set or compared to more formal constructions to general a        metric of grammatical formality. Comparing corpora could use one        of the similarity metrics (e.g., Jensen-Shannon) listed above.    -   A proportion of lowercase letters and uppercase letters can be        compared against a baseline metric of expected proportions for        formal writing styles or compared to one another using        similarity metrics (e.g., Jensen-Shannon) to determine        similarity of styles.    -   Identification of the proportion of misspellings or unknown        words compared to a dictionary can also provide indications of        the formality of the writing style. Again, this metric can be        compared to a typical baseline or similarity metrics can be used        to depict similarity (e.g., Jensen-Shannon).    -   Identification of slang words can also be used in combination        with the misspellings/unknown word calculations or separately. A        higher proportion of slang words can indicate lower levels of        formality. Similarity metrics (e.g., Jensen-Shannon) can be        applied to compare corpora.    -   A proportion of punctuation can indicate usage of punctuation.        Tracking the distribution of punctuation through the data can        also be an indicator of standard vs. nonstandard use of        punctuation. Sun et. al. (2019) mentioned using punctuation        distributions to characterize English usage, but not to compare        datasets. These metrics can also be compared to a standard or a        range, and can additionally be compared across corpora with        similarity metrics (e.g., Jensen-Shannon).

Another category of linguistic information that can ascertained for agiven textual dataset can be domain specificity. The domain specificitycategory can indicate whether the textual dataset relates to a specificdomain or is more general in nature. Within the category of domainspecificity can be several types of metrics that can be determined bythe processor. One type of metric can be term-specificity ratio, whichcan be computed by taking the ratio of domain-specific terms to the fullset of terms in the corpus to determine the relative domain specificityor information density of a corpus. The number of domain-specific termsmay be determined using term frequency or relative standard deviation.

Domain specificity can be used to characterize how much the language andgrammar of the dataset aligns to a general profile of the languageversus a more specialized profile of the language, or how close twodatasets align with respect to domain. It can be useful if thecomparison dataset (e.g., reference dataset) is either a generalrepresentation of the language or is a domain-specific representation ofthe language in the same domain as the target dataset. Some examplesfocus on the vocabulary represented in the datasets and on thegrammatical patterns that are known to represent domain-specific writingstyles in each language of interest based on linguistic research intothe grammatical patterns of various genres. These metrics are likely toreflect some of the metrics used above to compare vocabulary sets acrosscorpora (vocabulary diversity) or to compare grammatical pattern usage(language formality). Some examples can use grammar to compare corporato identify if they are in the same domain or a general domain. Someexamples of metrics that fall within the category of domain specificityare described below and can be obtained in multiple ways or in acombination of ways, including:

-   -   Listing the terms in each data set with a common threshold for        frequency (likely 3-4) and then determining the proportion of        overlap between the data sets. The more overlap, the more likely        the two datasets are from the same or a similar domain.    -   Listing the terms in the target dataset that do not overlap with        the reference/source dataset, so that the user can leverage that        list to find new data to tune the model. This may leverage the        approach used by Quero (2017).    -   The types of comparisons used in the vocabulary similarity        computations described above can be used to determine how        similar the vocabulary is across the two datasets. This same        approach can leverage topics instead of terms to compare the        datasets.    -   The research by Temnikova et. al. (2013) could be leveraged to        characterize datasets as domain-specific or not. That research        focused on token-type ratios, word-POS ratios, and vocabulary        comparisons.    -   Use of grammatical constructions that are markers of        domain-specific language, such as limited or repeated        constructions, could be used. This could be measured as a        comparison of structures found in a more general dataset        compared with structure in the target dataset. Dependency parse        trees or n-grams of part-of-speech tags could serve to represent        the patterns and structures. Proportions of constructions would        be used in comparing corpora leveraging one of the similarity        metrics (e.g., Jensen-Shannon) listed above.    -   Use of a dictionary approach can also help to determine the        number of unknown words in the dataset. When combined with the        metrics of formality, we can determine if the unknown word count        is due to errors like misspellings or due to specialized        terminology used in a domain.

It will be appreciated that the above examples of categories and themetrics therein are intended to be illustrative and non-limiting. Otherexamples may include more, fewer, or different categories than thosedescribed above. And other examples may include more, fewer, ordifferent metrics in each category than those described above.

In some example, the processor can test the target textual dataset forhomogeneity. In general, it can be desirable for the target textualdataset to be relatively homogeneous so that the model has a consistentlevel of accuracy across the entire target textual dataset. If thetarget textual dataset is not sufficiently homogeneous, the model mayperform better on some aspects of the target textual dataset than onother aspects of the target textual dataset, undermining the modelingresults. To flag this potential issue for the end user, in some examplesthe processor can test the target textual dataset for homogeneity andoutput results of the test to the user. One example of a process fortesting the homogeneity of the target dataset is described below withreference to FIG. 16.

In block 1602, the processor can segment the target textual dataset intoa set of subparts, as shown in box 1604. The processor can perform thissegmentation based on a stratification parameter. Examples of thestratification parameter can include date, time, genre, domain,language, etc. In some examples, the stratification parameter may bebias related (e.g., a stratification parameter for which there is aknown inherent bias). Examples of such bias-related stratificationparameters can include gender, race, ability, etc. The stratificationparameter may be chosen by a user (e.g., via the graphical userinterface) or may be a default parameter. One of example of choosingstratification parameter via the graphical user interface may involveselecting a checkbox or an item from a pull-down menu indicating thedesired stratification parameter.

In block 1606, the processor analyzes each subpart to determine a set ofmetrics for each subpart. The sets of metrics are shown in box 1608 ofFIG. 16. The processor can use any of the techniques described above todetermine the set of metrics for a given subpart, and the sets ofmetrics can each include any number and combination of the metricsdescribed above. In some example, the processor can determine the set ofmetrics for a given subpart based on the chosen stratification parameter

In step 1610, the processor determines whether each of the subparts ofthe target textual dataset satisfies a homogeneity criterion. A subpartmay satisfy the homogeneity criterion when the subpart is sufficientlysimilar to at least one other subpart such that the subparts may beconsidered relatively homogenous. To determine whether a particularsubpart is sufficiently similar to the at least one other subpart, theprocessor can compare the metrics for the particular subpart to themetrics for the at least one other subpart to generate one or moresimilarity values. This may be similar to the process described abovewith respect to block 1306 of FIG. 13. In this context, a similarityvalue may represent how similar two subparts are to one another. Ahigher similarity value may indicate a relatively high level ofsimilarity, which may mean that the two subparts are relativelyhomogenous. A lower similarity value may indicate a relatively lowerlevel of similarity, which may mean that the two subparts are relativelyheterogeneous. After determining the one or more similarity values, theprocessor can compare the one or more similarity values to one or morepredefined thresholds. If the one or more similarity values meet orexceed the one or more predefined thresholds, the processor candetermine that the subpart satisfies the homogeneity criterion.

In step 1612, the processor outputs a recommendation in the graphicaluser interface based on whether the subparts satisfy the homogeneitycriterion. If one or more of the subparts do not satisfy the homogeneitycriterion, then the target textual dataset as a whole may be consideredinsufficiently homogenous. So, the processor can generate arecommendation in the graphical user interface suggesting that the setof subparts be analyzed separately from one another using one or moremodels. For example, the processor can flag two or more non-homogeneoussubparts of the target textual dataset in the graphical user interfaceto assist the user in selecting proper models. If most (e.g., all) ofthe subparts satisfy the homogeneity criterion, then the target textualdataset can be considered as a whole to be sufficiently homogenous. So,the processor can generate another recommendation in the graphical userinterface suggesting that the target textual dataset be analyzed as awhole using the model.

In some examples, insights can be generated based each subpart of thetarget textual dataset. If there are no major differences between eachsubpart of the target textual dataset, then an insight could be that thetarget textual dataset is homogeneous. If there are major differencesbetween subparts of the target textual dataset, then an insight can bethat the target textual dataset is not homogeneous. The system can thusadvise user to apply different models to two or more of the subparts,where the model recommended for each subpart can be selected to optimizemodeling results for that subpart, to achieve an overall improvement tothe modeling results.

In some examples, the reference textual dataset described above mayserve as training data used to train the selected model, before theselected model is applied to the target textual dataset. In suchcircumstances, the process of FIG. 17 may be implemented. That processwill now be described below.

In block 1702, the processor trains a model using a reference textualdataset. An example of the model can be a machine-learning model, suchas a neural network. After training the model, the processor can analyzethe reference textual data to obtain a first set of metrics. Thisoperation can be performed similarly to operation 1302 of FIG. 13.

In block 1704, the processor obtains (e.g., receives) a target textualdataset that was not used to train the model. After obtaining the targettextual dataset, the processor can analyze the target textual data toobtain a second set of metrics. This operation can be performedsimilarly to operation 1304 of FIG. 13.

In block 1706, the processor determines a predicted level of degradationbased on differences between the first set of metrics and the second setof metrics. The predicted level of degradation can signify the risk ofaccuracy degradation if the model (that was trained using the referencetextual dataset) is applied to the target textual dataset. When thedifference between the first set of metrics and the second set ofmetrics is significant, the level of accuracy degradation may also besignificant. The processor can determine the predicted level ofdegradation based on the difference and provide the predicted level ofdegradation to the user so as to warn the user about the possibledegradation.

As one example, the processor can determine one or more similarityvalues between the first set of metrics and the second set of metricsusing any of the techniques described above. Based on the one or moresimilarity values, the processor can then determine the predicted levelof degradation. The processor may determine the predicted level ofdegradation using a predefined lookup table or one or more algorithms.For example, the similarity values can indicate a high level ofsimilarity (e.g., greater than 90% similarity) between two comparedmetrics. So, the processor can access a predefined lookup table thatmaps the similarity level to a predicted level of generation. Using sucha lookup table, the processor may determine that the predicted level ofdegradation is “low.” If the similarity values indicate a medium levelof similarity (e.g., greater than 80% similarity) between two comparedmetrics, then the processor can use the lookup table to determine thatthe predicted level of degradation is “medium.” If the similarity valuesindicate a low level of similarity (e.g., less than 80% similarity)between two compared metrics, then the processor can use the lookuptable to determine that the predicted level of degradation is “high.”The processor may take any number and combination of similarity valuescorresponding to any number and combination of metrics into account todetermine the predicted level of degradation.

In block 1708, the processor outputs the predicted level of modeldegradation in a graphical user interface. For example, the processormay output a numerical value (e.g., 20%) representing the predictedlevel of model degradation in the graphical user interface. As anotherexample, the processor may output a text representation of the predictedlevel of model degradation. For instance, the processor may output“high,” “medium,” or “low” depending how much degradation is predictedto occur, where “high” signifies more accuracy degradation than “low.”

One specific example can involve determining how well Model A that wastrained on a reference textual dataset (e.g., Corpus A) will work on thetarget textual dataset (e.g., Corpus B). This process can begin bydetermining how homogeneous the reference textual dataset is and howhomogeneous the target textual dataset is. Then the processes describedabove can be used to determine how different the reference textualdataset is from the target textual dataset. If the target textualdataset has long sentences and long words, it may be domain specific. Ifthe target textual dataset has short sentences and short words, it maybe informal or transcribed speech data. If the target textual datasethas misspellings and short sentences or few sentences, it may beinformal data. If the target textual dataset has different vocabularyand terms from the reference textual dataset, than the robustness of themodel on the target textual dataset may be lower. So, it may bedesirable to adjust the model type or model settings. Alternatively, themodel may need to be retrained or tuned for the target textual dataset.

In some example, the processor can suggest a model that may reduceresource consumption or have improved accuracy as compared to the modelselected by the user. For example, the user may select a deep learningmodel for use on the target textual dataset. But if the target textualdataset is relatively simple (e.g., in terms of linguistic variability),a deep learning model may be overkill. In such situations, the processormay determine and recommend an alternative model that can result inbetter accuracy, maintainability, or performance (e.g., reducedprocessing speeds and/or memory usage). Examples of such a process aredescribed in greater detail below with respect to FIG. 19.

In some examples, the processor can also determine whether the targettextual dataset should be preprocessed (e.g., further preprocessed)prior to the selected model being applied to the target textual dataset.If so, the processor can output a recommendation that one or moredata-preparation operations be applied to the target textual dataset. Adata-preparation operation can be a preprocessing operation configuredto be applied to the target textual dataset for transforming at leastone aspect of the target textual dataset in a way that makes it moreoptimized for (e.g., compatible with) the selected model. In general,the data-preparation operations may involve normalizing the targettextual dataset, removing one or more subparts from the target textualdataset, reformatting the target textual dataset from a first format toa second format, or any combination of these. One example of a processfor determining whether the target textual dataset should bepreprocessed will now be described below with reference to FIG. 18.

In block 1802, the processor analyzes a target textual dataset todetermine text characteristics thereof. For example, the processor candetermine sentence lengths in the target textual dataset, word spellingsin the target textual dataset, lengths of documents in the targettextual dataset, or any combination of these. Additionally oralternatively, the processor can determine any of the other metricsdescribed herein, which can indicate the text characteristics of thetarget textual dataset.

In block 1804, the processor determines one or more data-preparationrecommendations based on the text characteristics (e.g., the metrics).By analyzing the text characteristics, a data-preparation recommendationcan be generated to indicate whether the target textual dataset shouldbe preprocessed in a particular way. The data-preparation recommendationcan specify one or more data-preparation operations to apply to thetarget textual dataset to improve the model's results.

One example of a data-preparation operation can include removingextremely long sentences (e.g., sentences with a number of words orcharacters that exceeds a predefined threshold) in documents. Theprocessor can identify such long sentences by parsing through thesentences in the target textual dataset and computing their lengths. Itmay be desirable to remove extremely long sentences, since thosesentences is not really contain substantive content, but rather may beprogramming code, spreadsheets, or other undesirable text. Anotherexample of a data-preparation operation can include removing the textthat contains many misspelled words from the target textual dataset,since a large number of misspellings may indicate that the texts isinformal, which may not be as easy to process by a model as more formaltext. Many misspellings or unknown words may also mean that there isnon-text data, which is suboptimal for many models. The processor canidentify such misspellings and unknown words by parsing through thewords in the target textual dataset and comparing them to known words ina library. Still another example of a data-preparation operation caninclude correcting the misspelled words in the target textual dataset toimprove accuracy when the model is applied. Of course, thesedata-preparation operations are intended to be illustrative andnon-limiting. Other examples may include more, fewer, or different typesof data-preparation operations.

In block 1806, the processor outputs the data-preparation recommendationin a graphical user interface. For example, the processor can provideoutput a warning to the user in the graphical user interface indicatingthat that target textual dataset should be preprocessed before theselected model is applied. The processor may also output the one or morerecommended data-preparation operations.

In some examples, the processor can determine that modeling results maybe improved in relation to the target textual dataset if a certain typeof model or a certain model setting is used. One example of a processfor making such determinations is shown in FIG. 19, which is furtherdescribed below. Other examples may involve more operations, feweroperations, different operations, or a different order of the operationsthan is shown in FIG. 19.

In block 1902, the processor applies a set of rules, which may bepredefined. For example, the processor can apply the set of rules to oneor more metrics in a text profile for the target textual dataset.Additionally or alternatively, the processor can apply the set of rulesto the similarity value representing the similarity between the targettextual dataset and the reference textual dataset. Additionally oralternatively, the processor can apply the set of rules to a predictedlevel of model degradation. The processor can apply the set of rules toany one or more of the above to determine recommendations for the typeof model or the model settings to apply to the target dataset.

In block 1904, the processor determines a recommended type of model toapply to the target textual dataset based on the outcome of applying theset of rules. In one example, the processor can apply a set of rules toa similarity value generated by comparing the second set of metrics ofthe target textual dataset to the first set of metrics of the referencetextual dataset. The set of rules can include a threshold level for thesimilarity value. The processor can determine whether the similarityvalue is below to the threshold. If the similarity value is below thethreshold level, is may for example mean the target textual dataset doesnot have at least a certain level of similarity with respect to thereference textual dataset. So, the processor can determine that anothertype of model may perform better on the target textual dataset than themodel chosen by the user.

In another example, the processor can apply the set of rules to apredicted level of model degradation generated using the techniquesdescribed above. For example, the processor can determine whether thepredicted level of model degradation exceeds a threshold level. If thepredicted level of model degradation exceeds the threshold, it may forexample mean that the target textual dataset is at risk for low modelaccuracy. So, the processor can determine that another type of model mayperform better on the target textual dataset than the model chosen bythe user.

The processor can determine which type of model to recommend for a givenscenario using a selection process, through which the processor canselect a model type to recommend from among a set of candidate modeltypes. For example, the processor can determine a set of similarityvalues for a set of metrics or metric categories (e.g., informationcomplexity, vocabulary diversity, information density, languageformality, domain specificity). The similarity values may be determinedby comparing the first set of metrics and the second set of metrics.After computing the similarity values, the processor then can determinewhich metric or metric category has the highest similarity value. Usinga predefined lookup table that maps metrics or metric categories tomodels (e.g., model types), the processor can determine which modelcorresponds to the metric or metric category. The identified model maybe known to perform well in relation to that metric or metric category.In this way, the processor can determine a recommended model that mayyield better results than the model selected by the user.

For example, the reference textual dataset can include medical researchdocuments. After computing similarity values for each metric categorybetween the reference textual dataset and the target textual dataset,the two highest similarity values can be identified by the processor.The two highest similarity values may correspond to the metriccategories of language formality and domain specificity. Using thelookup table, the processor can determine a recommended type of modelthat functions well in a specific domain and with the applicable levelof language formality.

In another example, the processor can determine a predicted level ofmodel degradation separately in relation to each metric or metriccategory. After determining the predicted level of model degradation foreach metric or metric category, the processor then can determine whichmetric or metric category has the lowest predicted level of modeldegradation. The processor can then select a recommended type of modelthat is related (e.g., in a lookup table) to the determined metric ormetric category. For example, the reference textual dataset can includemedical research documents. After computing a predicted level of modeldegradation for each metric category between the reference textualdataset and the target textual dataset, the two of the predicted levelsof model degradation with the highest values can be identified by theprocessor. These two predicted levels of model degradation maycorrespond to the metric categories of language formality and domainspecificity. Using the lookup table, the processor can determine arecommended type of model that is more generically applicable and lessaffected by language formality and domain specificity.

In some examples, the processor can determine a recommended type ofmodel to apply to the target textual dataset based on the second set ofmetrics computed for the target textual dataset. Since some models(e.g., specific models or model types) may function better or worsebased on the textual characteristics of the target textual dataset, andthe textual characteristics can be represented by the second set ofmetrics, the second set of metrics can serve as a useful basis forselecting a model that will function well on the target textual dataset.In some such examples, the processor can access a predefined lookuptable that correlates certain metric values to certain models todetermine which model to recommend to the user. In situations where themetric values are correlated in the lookup table to multiple differentmodels, the metric values can be prioritized (e.g., depending on howinfluential they are on modeling results), so that the model that iscorrelated to the metric with the highest priority can be selected.

In block 1906, the processor outputs the recommended type of model in agraphical user interface. The user may then be able to select therecommended type of model via the graphical user interface to apply themodel to the target textual dataset.

In some examples, the system can determine a recommended type of modelto apply to the target textual dataset by applying a set of rules. Ifthe recommended type of model is different from a model type selected bythe user, the system can output a recommendation to the user to selectthe recommended model type to improve modeling results. The user maythen choose the recommended model type (e.g., from a list) using thegraphical user interface and apply the chosen model type to the targettextual data.

In block 1908, the processor can determine a recommended value for asetting of the model type based on the outcome of applying the set ofrules. In some examples, the recommended setting value can be arecommended hyperparameter value for the model type. The processor candetermine the recommended value for the setting using similar techniquesas described above.

In one example, the processor can apply a set of rules to a similarityvalue generated by comparing the second set of metrics of the targettextual dataset to the first set of metrics of the reference textualdataset. The set of rules can include a threshold level for thesimilarity value. The processor can determine whether the similarityvalue is below to the threshold. If the similarity value is below thethreshold level, is may for example mean the target textual dataset doesnot have at least a certain level of similarity with respect to thereference textual dataset. So, the processor can determine that anothermodel setting may improve modeling results.

In another example, the processor can apply the set of rules to apredicted level of model degradation generated using the techniquesdescribed above. For example, the processor can determine whether thepredicted level of model degradation exceeds a threshold level. If thepredicted level of model degradation exceeds the threshold, it may forexample mean that the target textual dataset is at risk for low modelaccuracy. So, the processor can determine that another model setting mayimprove modeling results.

The processor can determine which model setting to recommend for a givenscenario using a selection process, through which the processor canselect a value for a model setting to recommend from among a set ofcandidate setting values. For example, the processor can determine a setof similarity values for a set of metrics or metric categories (e.g.,information complexity, vocabulary diversity, information density,language formality, domain specificity). The similarity values may bedetermined by comparing the first set of metrics and the second set ofmetrics. After computing the similarity values, the processor then candetermine which metric or metric category has the highest similarityvalue. Using a predefined lookup table that maps metrics or metriccategories to setting values, the processor can determine which settingvalue corresponds to the metric or metric category. The identifiedsetting value may be known to produce good modeling results in relationto that metric or metric category. In this way, the processor candetermine a recommended setting value that may improve modeling results(e.g., as compared to an existing setting value or another baseline).

For example, the reference textual dataset can include medical researchdocuments. After computing similarity values for each metric categorybetween the reference textual dataset and the target textual dataset,the two highest similarity values can be identified by the processor.The two highest similarity values may correspond to the metriccategories of language formality and domain specificity. Using thelookup table, the processor can determine recommended values of one ormore settings that may improve modeling results for a specific domainand with the applicable level of language formality.

In another example, the processor can determine a predicted level ofmodel degradation in relation to each metric or metric category. Afterdetermining the predicted level of model degradation for each metric ormetric category, the processor then can determine which metric or metriccategory has the lowest predicted level of model degradation. Theprocessor can then select a recommended setting value that is related(e.g., in a lookup table) to the determined metric or metric category.For example, the reference textual dataset can include medical researchdocuments. After computing a predicted level of model degradation foreach metric category between the reference textual dataset and thetarget textual dataset, the two of the predicted levels of modeldegradation with the highest values can be identified by the processor.These two predicted levels of model degradation may correspond to themetric categories of language formality and domain specificity. Usingthe lookup table, the processor can determine a recommended settingvalue that reduces the effect of language formality and domainspecificity on modeling results, which can lead to improvements in modelaccuracy.

In some examples, the processor can determine a recommended settingvalue for a selected model based on the second set of metrics computedfor the target textual dataset. Since some model settings yield betteror worse results based on the textual characteristics of the targettextual dataset, and the textual characteristics can be represented bythe second set of metrics, the second set of metrics can serve as auseful basis for selecting model settings that may produce desirableresults in relation to the target textual dataset. In some suchexamples, the processor can access a predefined lookup table thatcorrelates certain metric values to certain setting values to determinewhich setting value to recommend to the user. In situations where themetric values are correlated in the lookup table to different values forthe same setting, the setting values can be prioritized (e.g., dependingon how influential they are on modeling results), so that the settingvalue that is correlated to the metric with the highest priority can beselected.

In block 1910, the processor outputs the recommended setting value in agraphical user interface. In one example, the system can apply a set ofrules to determine a recommended setting value for the model selected bythe user. If the recommended value for the setting is different from theexisting value of the setting, the system can output a recommendationthat the user update the setting to the recommended value to improvemodeling results. The user may then update the setting to therecommended value using the graphical user interface and apply the modelwith the updated setting value to the target textual data.

In the previous description, for the purposes of explanation, specificdetails are set forth in order to provide a thorough understanding ofexamples of the technology. But various examples can be practicedwithout these specific details. The figures and description are notintended to be restrictive.

The previous description provides examples that are not intended tolimit the scope, applicability, or configuration of the disclosure.Rather, the previous description of the examples provides those skilledin the art with an enabling description for implementing an example.Various changes may be made in the function and arrangement of elementswithout departing from the spirit and scope of the technology as setforth in the appended claims.

Specific details are given in the previous description to provide athorough understanding of the examples. But the examples may bepracticed without these specific details. For example, circuits,systems, networks, processes, and other components can be shown ascomponents in block diagram form to prevent obscuring the examples inunnecessary detail. In other examples, well-known circuits, processes,algorithms, structures, and techniques may be shown without unnecessarydetail in order to avoid obscuring the examples.

Also, individual examples may have been described as a process that isdepicted as a flowchart, a flow diagram, a data flow diagram, astructure diagram, or a block diagram. Although a flowchart can describethe operations as a sequential process, many of the operations can beperformed in parallel or concurrently. In addition, the order of theoperations can be re-arranged. And a process can have more or feweroperations than are depicted in a figure. A process can correspond to amethod, a function, a procedure, a subroutine, a subprogram, etc. When aprocess corresponds to a function, its termination can correspond to areturn of the function to the calling function or the main function.

Systems depicted in some of the figures can be provided in variousconfigurations. In some examples, the systems can be configured as adistributed system where one or more components of the system aredistributed across one or more networks in a cloud computing system.

The invention claimed is:
 1. A system comprising: one or moreprocessors; and one or more memory devices including instructions thatare executable by the one or more processors for causing the one or moreprocessors to: analyze a reference textual dataset by applying aplurality of text-mining techniques to the reference textual dataset togenerate a first text profile containing a first plurality of metricscharacterizing the reference textual dataset; analyze a target textualdataset by applying the plurality of text-mining techniques to generatea second text profile containing a second plurality of metricscharacterizing the target textual dataset; determine a similarity valuerepresenting how similar the target textual dataset is to the referencetextual dataset by comparing the second text profile to the first textprofile, wherein comparing the second text profile to the first textprofile involves comparing at least some of the second plurality ofmetrics to at least some of the first plurality of metrics; receive,through a graphical user interface and from a user, a selection of amodel that is to be applied to the target textual dataset; in responseto receiving the selection, determine characteristics of the modelselected by the user, wherein the characteristics include a type and atleast one setting of the model; generate one or more insights relatingto an anticipated accuracy of the model on the target textual datasetbased on the similarity value and the characteristics of the model; andoutput the one or more insights to the user in the graphical userinterface.
 2. The system of claim 1, wherein the one or more insightsinclude a predicted level of degradation in model accuracy as a resultof differences between the reference textual dataset and the targettextual dataset, wherein the reference textual dataset is training dataused to train the model, wherein the target textual dataset is new datanot used to train the model, and wherein the one or more memory devicesfurther include instructions that are executable by the one or moreprocessors for causing the one or more processors to determine thepredicted level of degradation based on differences between the firstplurality of metrics and the second plurality of metrics.
 3. The systemof claim 2, wherein the predicted level of degradation corresponds to apredicted amount of loss by the model.
 4. The system of claim 1, whereinthe one or more insights include a recommended value for a setting ofthe model, and wherein the one or more memory devices further includeinstructions that are executable by the one or more processors forcausing the one or more processors to determine the recommended value byapplying a set of rules to the second plurality of metrics in the secondtext profile of the target textual dataset, the recommended value of thesetting being configured to improve accuracy of the model as compared toanother value of the setting.
 5. The system of claim 4, wherein thesetting is a hyperparameter.
 6. The system of claim 1, wherein the oneor more insights include a recommended type of model to apply to thetarget textual dataset, the recommended type of model being differentfrom a model type selected by the user, and wherein the one or morememory devices further include instructions that are executable by theone or more processors for causing the one or more processors todetermine the recommended type of model from among a plurality ofcandidate model types by applying a set of rules to the second pluralityof metrics in the second text profile of the target textual dataset, therecommended type of model being capable of achieving a higher degree ofaccuracy in relation to the target textual dataset than the model typeselected by the user.
 7. The system of claim 6, wherein the plurality ofcandidate model types include a recurrent neural network, aconvolutional neural network, a long-short term memory model, aregression model, and a support vector machine.
 8. The system of claim1, wherein the second plurality of metrics includes at least two metricsselected from a group consisting of: a total number of function words, apercentage of uppercase letters to lowercase letters, a number ofsentences in a longest document by sentence count, an average number oftokens per sentence, a number of tokens in a longest sentence by tokencount, a total number of unique words, an average number of charactersper token, a number of characters or bytes in a longest token, a numberof unique tokens, a number of unique tokens to account for 80% of thetarget textual dataset, a percentage of tokens that are content, apercentage of tokens that are a number, and a percentage of tokens thatare punctuations.
 9. The system of claim 1, wherein the one or morememory devices further include instructions that are executable by theone or more processors for causing the one or more processors todetermine a data-preparation recommendation by analyzing the targettextual dataset, wherein the data-preparation recommendation indicateswhether the target textual dataset should be preprocessed using one ormore data-preparation operations before the model is applied to thetarget textual dataset.
 10. The system of claim 9, wherein the one ormore memory devices further include instructions that are executable bythe one or more processors for causing the one or more processors todetermine the data-preparation recommendation by analyzing sentencelengths in the target textual dataset, word spellings in the targettextual dataset, and lengths of documents in the target textual dataset.11. The system of claim 9, wherein the one or more data-preparationoperations include normalizing the target textual dataset, removing asubpart of the target textual dataset, or reformatting the targettextual dataset from a first format into a second format.
 12. The systemof claim 1, wherein the one or more memory devices further includeinstructions that are executable by the one or more processors forcausing the one or more processors to: segment the target textualdataset into a plurality of subparts based on a stratificationparameter; analyze the subparts to determine whether the target textualdataset satisfies a homogeneity criterion; and in response todetermining that the target textual dataset does not satisfy thehomogeneity criterion, generate a recommendation in the graphical userinterface suggesting that the plurality of subparts be analyzedseparately from one another using one or more models; or in response todetermining that the target textual dataset satisfies the homogeneitycriterion, generate another recommendation in the graphical userinterface suggesting that the target textual dataset be analyzed as awhole using the model.
 13. The system of claim 1, wherein the model is afirst model and the selection is a first selection, and wherein the oneor more memory devices further include instructions that are executableby the one or more processors for causing the one or more processors to,subsequent to outputting the one or more insights to the user in thegraphical user interface: receive, through the graphical user interfaceand from the user, a second selection of a second model to be applied tothe target textual dataset, the second model being different from thefirst model selected by the user; and execute the second model on thetarget textual dataset to generate an analysis result; and output theanalysis result in the graphical user interface for the user.
 14. Thesystem of claim 1, wherein the plurality of text-mining techniques areconfigured to analyze information complexity, vocabulary diversity,information density, language formality, and domain specificity of acorresponding dataset to which they are applied.
 15. The system of claim14, wherein the plurality of text-mining techniques are configured toanalyze the corresponding dataset using natural-language processing. 16.The system of claim 14, wherein a text-mining technique in the pluralityof text-mining techniques is configured to determine the domainspecificity of the corresponding dataset by: determining a frequency ofa set of words in the corresponding dataset, wherein the set of wordsare representative of a specific textual domain; determining a totalnumber of words in the corresponding dataset; and determining a ratio of(i) the frequency of the set of words to (ii) the total number of words;and determining the domain specificity based on the ratio.
 17. Thesystem of claim 1, wherein the similarity value is expressed as aquantitative value, and wherein the one or more memory devices furtherinclude instructions that are executable by the one or more processorsfor causing the one or more processors to: compute at least onedifference between (i) at least one metric of the first plurality ofmetrics and (ii) at least one corresponding metric of the secondplurality of metrics; and determine the quantitative value based on theat least one difference.
 18. The system of claim 1, wherein thereference textual dataset is configured to represent a particulartextual domain, genre, or language for purposes of comparison to thetarget textual dataset.
 19. The system of claim 1, wherein the one ormore memory devices further include instructions that are executable bythe one or more processors for causing the one or more processors tooutput the one or more insights as a sentence of words generated usingnatural-language generation techniques.
 20. The system of claim 1,wherein the reference textual dataset includes first unstructured text,and wherein the target textual dataset includes second unstructured textthat is different from the first unstructured text.
 21. A methodcomprising: analyzing, by one or more processors, a reference textualdataset by applying a plurality of text-mining techniques to thereference textual dataset to generate a first text profile containing afirst plurality of metrics characterizing the reference textual dataset;analyzing, by the one or more processors, a target textual dataset byapplying the plurality of text-mining techniques to generate a secondtext profile containing a second plurality of metrics characterizing thetarget textual dataset; determining, by the one or more processors, asimilarity value representing how similar the target textual dataset isto the reference textual dataset by comparing the second text profile tothe first text profile, wherein comparing the second text profile to thefirst text profile involves comparing at least some of the secondplurality of metrics to at least some of the first plurality of metrics;receiving, by the one or more processors, a selection of a model that isto be applied to the target textual dataset, the selection beingreceived through a graphical user interface from a user; in response toreceiving the selection, determining, by the one or more processors,characteristics of the model selected by the user, wherein thecharacteristics include a type and at least one setting of the model;generating, by the one or more processors, one or more insights relatingto an anticipated accuracy of the model on the target textual datasetbased on the similarity value and the characteristics of the model; andoutputting, by the one or more processors, the one or more insights tothe user in the graphical user interface.
 22. The method of claim 21,wherein the one or more insights include a predicted level ofdegradation in model accuracy as a result of differences between thereference textual dataset and the target textual dataset, wherein thereference textual dataset is training data used to train the model,wherein the target textual dataset is new data not used to train themodel, and further comprising determining the predicted level ofdegradation based on differences between the first plurality of metricsand the second plurality of metrics.
 23. The method of claim 21, whereinthe one or more insights include a recommended value for a setting ofthe model, and further comprising determining the recommended value byapplying a set of rules to the second plurality of metrics in the secondtext profile of the target textual dataset, the recommended value of thesetting being configured to improve accuracy of the model as compared toanother value of the setting.
 24. The method of claim 21, wherein theone or more insights include a recommended type of model to apply to thetarget textual dataset, the recommended type of model being differentfrom a model type selected by the user, and further comprisingdetermining the recommended type of model from among a plurality ofcandidate model types by applying a set of rules to the second pluralityof metrics in the second text profile of the target textual dataset, therecommended type of model being capable of achieving a higher degree ofaccuracy in relation to the target textual dataset than the model typeselected by the user.
 25. The method of claim 21, further comprisingdetermining a data-preparation recommendation by analyzing the targettextual dataset, wherein the data-preparation recommendation indicateswhether the target textual dataset should be preprocessed using one ormore data-preparation operations before the model is applied to thetarget textual dataset.
 26. The method of claim 21, further comprising:segmenting the target textual dataset into a plurality of subparts basedon a stratification parameter; analyzing the subparts to determinewhether the target textual dataset satisfies a homogeneity criterion;and in response to determining that the target textual dataset does notsatisfy the homogeneity criterion, generating a recommendation in thegraphical user interface suggesting that the plurality of subparts beanalyzed separately from one another using one or more models; or inresponse to determining that the target textual dataset satisfies thehomogeneity criterion, generating another recommendation in thegraphical user interface suggesting that the target textual dataset beanalyzed as a whole using the model.
 27. The method of claim 21, whereinthe plurality of text-mining techniques are configured to analyzeinformation complexity, vocabulary diversity, information density,language formality, and domain specificity of a corresponding dataset towhich they are applied.
 28. The method of claim 21, wherein atext-mining technique in the plurality of text-mining techniques isconfigured to determine domain specificity of a corresponding datasetby: determining a frequency of a set of words in the correspondingdataset, wherein the set of words are representative of a specifictextual domain; determining a total number of words in the correspondingdataset; and determining a ratio of (i) the frequency of the set ofwords to (ii) the total number of words; and determining the domainspecificity based on the ratio.
 29. The method of claim 21, wherein thesimilarity value is expressed as a quantitative value, and furthercomprising: computing at least one difference between (i) at least onemetric of the first plurality of metrics and (ii) at least onecorresponding metric of the second plurality of metrics; and determiningthe quantitative value based on the at least one difference.
 30. Anon-transitory computer-readable medium comprising program code that isexecutable by one or more processors for causing the one or moreprocessors to: analyze a reference textual dataset by applying aplurality of text-mining techniques to the reference textual dataset togenerate a first text profile containing a first plurality of metricscharacterizing the reference textual dataset; analyze a target textualdataset by applying the plurality of text-mining techniques to generatea second text profile containing a second plurality of metricscharacterizing the target textual dataset; determine a similarity valuerepresenting how similar the target textual dataset is to the referencetextual dataset by comparing the second text profile to the first textprofile, wherein comparing the second text profile to the first textprofile involves comparing at least some of the second plurality ofmetrics to at least some of the first plurality of metrics; receive,through a graphical user interface and from a user, a selection of amodel that is to be applied to the target textual dataset; in responseto receiving the selection, determine characteristics of the modelselected by the user, wherein the characteristics include a type and atleast one setting of the model; generate one or more insights relatingto an anticipated accuracy of the model on the target textual datasetbased on the similarity value and the characteristics of the model; andoutput the one or more insights to the user in the graphical userinterface.